Mia‑Platform makes this component available on its platform as an easily deployable and configurable saga orchestrator, fully integrated with the other features of the platform.
Using the Mia‑Platform Flow Manager allows you to configure the saga in a few simple steps. In this way it is possible to save time compared to developing a customized solution; moreover, it offers considerable advantages in terms of business logic management, debugging, and flexibility, in the event of evolution or changes in requirements.
The central orchestrator was developed as a platform’s standard service
The advantages are immediately evident. To meet the specific project needs it is sufficient to define the finite state diagram that describes the possible flows of interactions and translate it into a simple configuration file.
Furthermore, it is possible to obtain a simple and clean solution: the entire business logic is concentrated not only in the code of a single service – an intrinsic advantage of the orchestrator approach – but even in a single file.
Using a ready‑to‑configure and ready‑to‑release component allowed us to significantly save time on the project. Developing a microservice from scratch that manages communication with the other components, carries on the flow of the saga, and guarantees the necessary robustness has a considerable cost: an extra two months, according to our estimates.
Besides saving resources during development, another advantage that emerged during the UAT was the flexibility of the system in case of changes in requirements.
With our approach, if the business specifications vary, once the actors involved have been prepared, changing the flow only involves a few changes and adaptations, that are:
- editing the isolated logic of the service/services involved;
- editing the orchestrator’s configuration file.
Also, in the event of a single change to the flow, which doesn’t impact the logic, it may be sufficient to change the configuration file, without modifying the code.
Therefore, this avoids having to modify the orchestrator code, recompose the pre‑existing flow, apply the change and explicitly manage the aspects of communication with the other services: operations that would have been necessary if we used an ad‑hoc implemented orchestrator to manage the specific flow.
For example, if you wanted to add a phase in the saga – let’s say the verification of user data – the classic approach would require to modify the code, check where to insert this new step, and modify the entire flow.
Otherwise, with the approach proposed in Mia‑Platform, once the actors involved in the change have been prepared, it is sufficient to change a configuration file by adding the new step.
This approach proposes a simplification of the required modification interventions, with a considerable time and resources saving.
Is configuring our saga easy?
With the Flow Manager, everything you need to orchestrate the saga is:
- Adding the flow‑manager plugin: