Quick revision
The short answer
The decision turns on how many long-running processes we have and how often their rules change, the total cost of licences or managed fees against the engineering time we spend building state machines, retries and tooling, the operational risk of a new critical dependency with its availability, upgrade path and exit options, and the quality of the Java developer experience, especially testing and versioning of in-flight workflows. I would structure it as an evaluation with explicit criteria and a pilot on one real process before any broader adoption.
What to remember
In this answer, we framed buying a workflow platform against continuing to build sagas as a comparison between one shared product and many partial copies. We weighed demand, the number, complexity and change rate of long-running processes, against five-year total cost on both sides, the operational risk and exit options of a new critical dependency, and the Java developer experience including testing and versioning of in-flight workflows. Then we structured the decision with agreed criteria, a shortlist that includes a shared internal build, and a pilot on one real process before broader adoption.
Your turn
Answer it aloud as you would in the interview, or type your answer below. Then show one part at a time and compare.
The decision turns on how many long-running processes we have and how often their rules change, the total cost of licences or managed fees against the engineering time we spend building state machines, retries and tooling, the operational risk of a new critical dependency with its availability, upgrade path and exit options, and the quality of the Java developer experience, especially testing and versioning of in-flight workflows. I would structure it as an evaluation with explicit criteria and a pilot on one real process before any broader adoption.
Why this question is asked
Every company that runs sagas ends up building parts of a workflow engine: state tables, retry schedulers, timeout jobs, admin screens for stuck instances. At some point someone asks whether we should buy one instead. It is a classic build-versus-buy decision with a twist, because the platform would sit in the middle of the company's most important business processes. Interviewers ask it at the twenty-year level to see how we structure a decision with long consequences. In this answer, we will look at what we are really comparing, then go through the factors, demand, cost, operational risk and developer experience, and finish with how we would run the decision and the pilot.
1What We Are Actually Comparing
A workflow orchestration platform, for example Temporal, Camunda or a cloud provider's managed workflow service, runs business processes as durable workflows. It stores each instance's state, schedules retries and timers, survives crashes by resuming instances, versions process definitions, and gives a UI to inspect and repair instances. Our own sagas do the same things, built per service: a saga table, an outbox, a scheduled job for deadlines, some custom admin endpoints.
So the comparison is not platform versus nothing. It is a shared, specialised product against many partial copies of it, each maintained by a different team. Making that visible is the first step, because the cost of the home-grown copies is usually spread across team budgets and nobody has added it up.
2Demand: How Many Processes, and How Often They Change
The first factor is demand. We count the long-running processes, those that span several services or wait for hours or days on people, partners or timers, and how complex they are. Five simple sagas that finish in seconds are a different problem from twenty processes with approvals, escalations and month-long timers.
Then we look at the rate of change. If the business changes onboarding rules every few weeks, the hardest part of a home-grown saga is changing the flow while thousands of instances are halfway through the old version. Platforms solve that with workflow versioning. If processes rarely change, that advantage matters less.
3Total Cost on Both Sides
On the buy side we count licence or managed service fees, which often scale with executions or actions, so we price them at our five-year volume, not today's; the platform team or the share of a team needed to run it; and integration and migration effort. On the build side we count the engineering time spent today and expected later: building and maintaining state machines, retry and timeout logic, recovery jobs, admin tools and dashboards, multiplied by the number of teams doing it, plus the cost of incidents caused by bugs in that code.
| Item | Keep building | Buy platform |
|---|---|---|
| Licence or managed fees | 0 | about 150k per year at projected volume |
| Platform operation | 0 | 2 engineers |
| Saga plumbing in teams | about 6 engineers across 12 teams | about 1 engineer total |
| Incidents from saga bugs | 8 per year, 2 costly | expected lower, to be proven |
| Migration | 0 | one-off, about 3 engineer-years |
4Operational Risk and Exit
A workflow platform becomes a critical dependency. If it is down, every process on it stops starting and advancing. So we check how it achieves high availability, what its own storage is, for example a database cluster underneath a self-hosted engine, what happens to running workflows during an upgrade, and what the vendor's support and incident history look like. For a managed service, we check its regions and SLA against our own availability target.
Then exit options. Workflow code written against a platform's SDK is not portable, so leaving means rewriting the processes and migrating in-flight instances. We look at the licence, whether there is an open-source core we could run ourselves if the vendor changed terms, and how hard it would be to export history for audit. The cost of leaving should be known before we enter.
5Developer Experience in Java
Engineers will write and debug these workflows every day, so the Java SDK matters. We check how natural the programming model is, whether workflows are plain Java code, as in Temporal, or BPMN models with Java delegates, as in Camunda, and the constraints it imposes, such as Temporal's requirement that workflow code be deterministic so that it can be replayed. We check Spring Boot integration and how activities call our existing services.
Testing support is decisive: can a developer run a workflow in a unit test with time skipping, so a 30-day timer runs in milliseconds, and replay recorded histories against new code to prove a change is safe for in-flight instances? Versioning in-flight workflows is the feature people underestimate; we ask to see it working in the pilot, not in a slide.
6Structuring the Decision
We write the criteria down first, with weights agreed with engineering and business leadership: demand, five-year cost, operational risk, exit cost and developer experience. We shortlist two or three options, including building a shared internal library as the build option, so that buy is compared with the best version of build, not with today's scattered code.
Then we pilot one real process, ideally one that is long-running and painful today, with success criteria set in advance: time to implement compared with our estimate for building it, the incident rate and time to diagnose a stuck instance, the effort to change the flow with instances in flight, and measured cost at production volume. After a fixed period we decide: adopt for a class of processes, extend the pilot, or keep building with a shared library.
- Inventory processes and current costscount, complexity, change rate
- Agree weighted criteriawith engineering and business
- Shortlist options, including a shared build
- Pilot one painful processfixed period, success criteria set up front
- Criteria met?YesAdopt for that class of processNoExtend pilot or keep building
5 steps in order. Play them, or step through them one at a time.
7Follow-up questions
What if the teams already have working sagas?
Then they keep them until there is a reason to move. A platform decision does not have to mean migrating everything; new long-running processes start on the platform, and existing ones move when they need a major change or keep causing incidents. Forcing a rewrite of a stable saga spends money for little return.
Is a self-hosted open-source engine cheaper than a managed service?
The licence is cheaper, but we pay in operations: running the engine's cluster and its database, upgrades, backups, on-call. For a company without a strong platform team, a managed service is often cheaper in total. I would price both in the same cost table.
How do you avoid lock-in?
Keep business logic in our services and activities, so the workflow code only sequences calls, and keep that sequencing thin. Then leaving means rewriting orchestration code, not business rules.
8Conclusion
In this answer, we framed buying a workflow platform against continuing to build sagas as a comparison between one shared product and many partial copies. We weighed demand, the number, complexity and change rate of long-running processes, against five-year total cost on both sides, the operational risk and exit options of a new critical dependency, and the Java developer experience including testing and versioning of in-flight workflows. Then we structured the decision with agreed criteria, a shortlist that includes a shared internal build, and a pilot on one real process before broader adoption.
Open with
I would frame it as one shared product against the many partial workflow engines our teams are already building, because every saga today has its own state table, retries, timeout jobs and admin tools.
Then, if they want more
The factors I would weigh are, first, demand: how many long-running processes we have, how complex they are and how often the business changes them, since changing a flow with instances in flight is the hardest thing to build ourselves.
Second, total cost over five years: licence or managed fees at projected volume and the people to run the platform, against the engineering time spent on custom state machines, retries and tooling across all teams, plus incidents from bugs in that code.
Third, operational risk: the platform becomes a critical dependency, so I look at its high availability, upgrade path, support and exit options, including licence terms and how hard it would be to leave. Fourth, developer experience in Java: SDK quality, Spring Boot integration, testing with time skipping and replay, and versioning of in-flight workflows.
To structure it, I would agree weighted criteria with engineering and business leaders, compare buying against the best version of building, a shared internal library, and run a pilot on one painful real process with success criteria set up front, then decide on broader adoption from the results.
About this answer
- Last updated
- 12 November 2026
- Checked
- Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the documentation below. What the checks cover
- Where the question comes from
- Written by Scrivio for practice. It is not taken from an interview.
- Official documentation
- Spring Cloud documentation, Resilience4j documentation
Report an issue with this answer
Copy the line below and send it to the author with what you found. It carries the address of this page.
Issue with "Your company is deciding whether to buy a commercial workflow orchestration platform or...": https://scrivio-interview-library.netlify.app/spring-boot/distributed-data/b327969975/