Master's Thesis
Nebula: A DSL for Domain-Driven Microservices with Sagas
— 2026
Key information
Authors:
Supervisors:
Published in
May 26, 2026
Abstract
Microservices architectures introduce significant complexity in maintaining data consistency across service boundaries, particularly when coordinating distributed transactions. Sagas, the dominant pattern for cross-service coordination, require substantial implementation effort and are error-prone when coded manually. This thesis presents Nebula, a DSL that bridges high-level DDD concepts and microservices implementation details. Nebula lets developers express aggregates, entities, invariants, and distributed workflows in domain terminology, automatically generating Java code for a microservices simulator. It provides first-class support for Saga orchestration with compensation logic and semantic locks, and integrates with VS Code through the Langium framework for real-time validation and semantic analysis. On the simulator framework's showcase domain, 281 lines of Nebula DSL compile into 6,836 lines of Java across 144 files, a 1:24 amplification consistent across two further domains. Compared against a hand-written reference of the same Quizzes Tutor domain, 669 lines of Nebula produce Java output within 4% of the manually authored size, capturing the same structural information from a roughly thirty-fold smaller model file.
Publication details
Authors in the community:
Supervisors of this institution:
Fields of Science and Technology (FOS)
electrical-engineering-electronic-engineering-information-engineering - Electrical engineering, electronic engineering, information engineering
Publication language (ISO code)
eng - English
Rights type:
Embargoed access
Date available:
April 30, 2027
Institution name
Instituto Superior Técnico