The overall architecture
Decision support and payments run separately. Which conditions ensure the result?
Rule calculation must not trigger payment.
Starting point A separate review path ends with reasoned confirmation or amendment.
Assumptions for the example case
A fictional municipal training example with a fixed grant of 300 euros. Caseworkers make the decision; a rules checker provides reasoned guidance. The design specifies no real eligibility requirements. All quantities, thresholds and operational targets are illustrative assumptions.
Decision support and payments
Decision support and payments
The API and workers share the case datastore; evidence documents are stored separately; external payment responses enter the inbox through the API.
Responsibilities within the application
Benefits case modules
Applications, decision support, decision notices, payments and appeals have separate responsibilities.
Runtime components and authoritative data
- Runtime boundary
- Applicant portal and caseworker interface → benefit case API → relational case datastore. Evidence storage holds documents; the rules worker reads approved rule versions and writes decision support. Payment worker → external payment service, using committed instructions; feedback → API → the same case. The appeals team uses separately authorised case access.
- Module responsibilities
- Application management tracks submissions and evidence requests. Rule checking produces versioned decision support. Decision notices record reasoned decisions. Payment coordination tracks instructions that take effect once. Appeals connect challenges to resulting decisions.
Decision support and payments run separately.
Only a committed approval opens a payment instruction.
Rule calculation must not trigger payment.
Application management and decision-notice management belong to the API. The rules worker calculates; the payment worker transports commands; both use the case data store.
- Alternative considered
- Calling the payment worker before commit could pay without a committed decision.
- Trade-off
- Outbox processing is deferred.
- Reassess
- Higher load can deepen worker separation.
Try it yourself
Assign modules and processes.
A hint for your attempt
Rule calculation must not trigger payment.
Compare with a possible solution
- Modules
- Application and decision-notice modules run inside the API.
- Processes
- The rules worker calculates; the payment worker sends instructions; both use the case datastore.
Apply to your project
How does this principle apply in your own project: Decision support and payments run separately.