Scrivio Interview library
LeadershipAdvanced6 min read · updated 12 November 2026

Several teams are building their own saga frameworks. Would you adopt a workflow engine (for example Temporal or Camunda) as a company standard? How would you decide?

I would not decide by preference. I would list what long-running flows actually need (durable state, timers, retries, visibility and versioning of running flows), compare the cost of running a workflow engine such as Temporal or Camunda with the hidden cost of many home-grown saga frameworks, and prove the choice with a pilot on one complex flow. Alongside that, I would define when a saga is needed at all, because some flows are better redesigned to stay inside one service.

Why this question is asked

When several teams each build a saga framework, the company ends up paying several times for the same hard problem, and each copy has its own bugs in timers, retries and recovery. At the same time, a workflow engine is not a library we add and forget; it becomes critical infrastructure that every order or claim depends on. Interviewers ask this leadership question to see whether we can make a platform decision with evidence rather than enthusiasm. In this answer, we will look at what the teams' frameworks are really trying to provide, what an engine gives and what it costs, how to compare the two honestly, how to run a pilot, and how to reduce the number of sagas in the first place.

1What the Teams Are Really Building

A saga framework, whoever writes it, has to solve the same set of problems. It needs durable state, so a flow survives a restart halfway through. It needs timers, so a step can wait for a reply for ten minutes or a payment for three days. It needs retries with backoff and limits. It needs visibility, so support can see where order 42 is and why. And it needs versioning, because a flow that started last week under the old code must finish correctly after we deploy new code.

The last two are where custom frameworks usually fall short. Durable state and retries get built in the first month. Visibility arrives as a few log lines, and versioning of in-flight flows is often discovered only when a deployment breaks hundreds of running sagas. So the first thing I would do is write these requirements down and ask each team how their framework handles each one today.

Requirements and who provides them
RequirementCustom frameworkWorkflow engine
Durable state across restartsa saga table per teambuilt in, event history
Timers of minutes to daysscheduled pollersdurable timers
Retries with backoffhand-written per stepdeclared per activity
Visibility of each instancelogs, ad hoc queriesUI and query API
Versioning running flowsoften missingversioning APIs, still needs care
Operations and upgradesspread over teamsone platform team, critical service
The rows in the middle of the table are where custom frameworks quietly cost the most.

2What an Engine Gives and What It Costs

An engine gives these requirements out of the box. Temporal, for example, lets us write the flow as ordinary Java code whose state is recorded as an event history, so the code can pause for days and resume after a crash. Camunda models the flow as BPMN, a standard process diagram notation, which business analysts can read. Both give a UI where we can see every running instance.

The cost is real too. The engine is a new critical platform: if the Temporal cluster or the Camunda engine is down, no orders move. Someone must run it, upgrade it, back it up and be on call for it. Developers must learn its programming model; with Temporal, for instance, workflow code must be deterministic, so it cannot call the clock or a random generator directly and must use the engine's APIs instead. And the company becomes dependent on the engine's vendor or community for years.

3Comparing the Costs Honestly

The custom option looks free because its costs are spread out. To compare fairly, I would estimate them: how many engineer weeks each team spent building and maintaining its framework, how many incidents in the last year were caused by stuck or broken sagas, and how long it takes to answer 'where is this order?' today. If five teams each spend six engineer weeks a year on their framework, that is thirty weeks a year, before counting incidents.

On the engine side, I would estimate the platform team's time to run it, hosting or license cost, training, and the migration effort for existing flows. If the engine costs one and a half engineers to run and removes most of thirty weeks of duplicated work plus most saga incidents, the case is clear. If only one team has complex flows, it is not.

4Running a Pilot

I would not mandate an engine company-wide on paper. I would pick one complex, real flow, ideally one with long waits and compensations such as order fulfilment or insurance claims, and have one team build it on the candidate engine, with the platform team running the engine in production.

Before starting, we agree what we will measure: developer effort to build and change the flow, time to diagnose a stuck instance, operational issues with the engine itself over a few months, and how a code change to a running flow went. The pilot ends with a written result and a decision: adopt as the standard for flows that meet certain criteria, adopt for that team only, or stop.

Step throughDeciding on a workflow standard
  1. List requirements per teamdurable state, timers, retries, visibility, versioning
  2. Can the flow live in one service?
    YesRedesign it, no saga neededNoKeep it as a saga candidate
  3. Measure today's hidden costengineer weeks, saga incidents, diagnosis time
  4. Pilot one complex flow on the enginewith the platform team running it
  5. Did it beat the custom option?
    YesAdopt as standard for qualifying flowsNoKeep a small shared library instead

5 steps in order. Play them, or step through them one at a time.

5Asking Whether We Need Sagas at All

Part of the decision is reducing demand. A saga exists because data that changes together lives in different services. Sometimes that split is right, for example when payment is a separate system with its own compliance needs. Often it is an accident of how teams were organised, and the flow would be simpler, faster and safer as one local transaction inside one service.

So the standard I would publish has two parts. First, a short guide for when a cross-service flow is justified, with the default being to keep things that must change together in one service. Second, for flows that are justified, the chosen tool: the engine for long-running, multi-step flows with compensations and timers, and plain events with an outbox for simple one-step reactions.

6Follow-up questions

What if a team refuses to move off its own framework?

I would not force a migration of working flows without a reason. New flows use the standard, and existing ones move when they need significant change or cause incidents. Showing the pilot's numbers and offering platform support for the migration persuades most teams better than a mandate.

Temporal or Camunda?

It depends on who designs the flows and how. Temporal suits developers who want flows as code with strong durability guarantees. Camunda suits organisations where analysts model processes in BPMN and want human tasks. I would let the pilot and the requirements decide, and check licensing and hosting terms for the version we would run.

How do you avoid lock-in to the engine?

We keep business logic in ordinary services and activities that the engine calls, so the engine holds orchestration and state but not the rules. That keeps a future migration expensive but possible, and it also keeps the domain code testable without the engine.

7Conclusion

In this answer, we saw that the decision starts from requirements every saga framework must meet: durable state, timers, retries, visibility and versioning of running flows. A workflow engine provides them but becomes a critical platform with its own learning curve and operating cost, so we compare it with the hidden, spread-out cost of many custom frameworks and prove the choice with a measured pilot. Finally, we reduce the number of sagas by keeping data that changes together in one service.

What to say in the interviewAbout 80 seconds aloud

Open with

I would treat it as a platform decision that needs evidence. First I would write down what these frameworks must provide: durable state across restarts, timers that can wait for days, retries with limits, visibility into each running instance, and safe versioning of flows that are in flight during a deployment.

Then, if they want more

Then I would ask each team how its framework handles each of these, because visibility and versioning are usually where custom code is weakest.

A workflow engine like Temporal or Camunda gives those features out of the box, but it is a new critical platform: it must be operated, upgraded and on call, developers must learn its model, and we depend on it for years.

So I would compare its cost with the hidden cost of the custom frameworks, the engineer weeks spent maintaining them and the incidents from stuck sagas. Then I would run a pilot on one complex real flow, with clear measures for development effort, diagnosis time and operational issues, and decide based on the result.

I would also publish guidance on when a saga is needed at all, because many flows are simpler as a single transaction inside one service, and the best saga is the one we do not need.

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.
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 "Several teams are building their own saga frameworks. Would you adopt a workflow engine...": https://scrivio-interview-library.netlify.app/spring-boot/event-driven-patterns/4b097ce2cd/