ADR: diploma-eligibility DMN evaluated as a BPMN businessRuleTask (S-13) #100
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Recorded ahead of S-13 (#14) per CLAUDE.md §14 (non-obvious decision + touches the workflow boundary). ADR file will land as
docs/architecture/adr-0016-*.mdin the implementing PR.Decision to be made: Where is the diploma-eligibility DMN evaluated, and how does it drive the foreign→CBGV-advies routing?
Context / forces: The Flowable REST app bundles a DMN engine, and the same
repository/deploymentsendpoint that deploysregistratie.bpmncan deploy a.dmn. §8.2 makes the Workflow Client the only code that talks to Flowable; the PRD frames the workflow as "BPMN + DMN governing the registration workflow" (orchestration via Flowable as a peer module). The registration must carry a diploma origin (domestic/foreign; eIDAS ⇒ foreign) as the decision input.Options considered:
businessRuleTask(chosen). Flowable evaluates the deployeddiploma-eligibilityDMN inline as a workflow step; an exclusive gateway routes foreign diplomas through a newCBGVAdviesuser task beforeBeoordelen, domestic straight toBeoordelen. Decision logic lives in the engine.Proposed option + why: Option 1. It keeps the decision a first-class workflow concern (matching the PRD's BPMN+DMN framing), avoids coupling the domain to Flowable for a decision, and keeps §8.2 clean — the process the Workflow Client already started runs the DMN itself. The domain's only new responsibility is carrying the diploma origin and passing it as a start variable.
Consequences: The registratie process gains a
businessRuleTask+ exclusive gateway +CBGVAdviesuser task; the DMN is version-controlled inworkflows/and deployed like the BPMN. The DMN is validated live (evaluated in isolation via the DMN API + the foreign path exercised through the process), consistent with ADR-0009/0014/0015. Deviates from #14's literal "evaluated by the Domain Service via Workflow Client" wording — noted on the issue.Coupling rules touched (CLAUDE.md §8): §8.2 — upheld. The Workflow Client remains the only code talking to Flowable; the DMN runs inside the engine as part of the process, not via a domain round-trip.