fix(infra): deploy diploma-eligibility DMN via dmn-api, not a process .bar (refs #14)
CI / lint (pull_request) Successful in 1m18s
CI / build (pull_request) Successful in 1m3s
CI / unit (pull_request) Successful in 1m9s
CI / frontend (pull_request) Successful in 2m37s
CI / mutation (pull_request) Successful in 5m27s
CI / verify-stack (pull_request) Successful in 7m39s
CI / lint (pull_request) Successful in 1m18s
CI / build (pull_request) Successful in 1m3s
CI / unit (pull_request) Successful in 1m9s
CI / frontend (pull_request) Successful in 2m37s
CI / mutation (pull_request) Successful in 5m27s
CI / verify-stack (pull_request) Successful in 7m39s
flowable-rest does not cascade a .dmn bundled inside a process .bar into the DMN engine: the resource is stored but no decision is created, so the DMN service task fails at runtime with FlowableObjectNotFoundException. Deploy the DMN to the DMN engine via /dmn-api/dmn-repository/deployments and the BPMN to the process engine separately; the service task resolves the decision across deployments by key (verified live: Buitenlands->CBGV_ADVIES, Binnenlands->DIRECT). Also move the DMN's doc comment inside <definitions>: Flowable's DMN XML converter rejects a comment between the <?xml?> declaration and the root element (XMLStreamReader not in START_DOCUMENT/START_ELEMENT state), unlike its BPMN one. seed-config.sh now seeds both raw workflow files instead of building a .bar. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
+8
-13
@@ -35,18 +35,13 @@ populate() { # volume source(file or dir/.)
|
||||
|
||||
[ "$#" -gt 0 ] || { echo "usage: seed-config.sh <oz|nrc|kc|fl> ..." >&2; exit 2; }
|
||||
|
||||
# The registratie process and its diploma-eligibility DMN must land in ONE Flowable deployment, so the
|
||||
# process's inline DMN service task resolves the decision by its (shared) parent deployment id (S-13,
|
||||
# ADR-0016). We bundle both into a single .bar (zip) and deploy that one artefact.
|
||||
build_flowable_bar() {
|
||||
local out="$1"
|
||||
python3 - "$here/../workflows/registratie.bpmn" "$here/../workflows/diploma-eligibility.dmn" "$out" <<'PY'
|
||||
import sys, zipfile
|
||||
bpmn, dmn, out = sys.argv[1:4]
|
||||
with zipfile.ZipFile(out, "w", zipfile.ZIP_DEFLATED) as z:
|
||||
z.write(bpmn, "registratie.bpmn")
|
||||
z.write(dmn, "diploma-eligibility.dmn")
|
||||
PY
|
||||
# The registratie process (BPMN) and its diploma-eligibility DMN are deployed as SEPARATE Flowable
|
||||
# deployments — the process engine and the DMN engine each own theirs (S-13, ADR-0016). flowable-rest
|
||||
# does not cascade a .dmn bundled in a process .bar into the DMN engine, so we seed both raw files and
|
||||
# let flowable-init deploy each via its own REST app. We stage them in a temp dir and copy its contents.
|
||||
stage_flowable_workflows() {
|
||||
local dir="$1"
|
||||
cp "$here/../workflows/registratie.bpmn" "$here/../workflows/diploma-eligibility.dmn" "$dir/"
|
||||
}
|
||||
|
||||
for key in "$@"; do
|
||||
@@ -54,7 +49,7 @@ for key in "$@"; do
|
||||
oz) populate rr-oz-config "$here/openzaak/setup_configuration/." ;;
|
||||
nrc) populate rr-nrc-config "$here/opennotificaties/setup_configuration/." ;;
|
||||
kc) populate rr-kc-realms "$here/keycloak/realms/." ;;
|
||||
fl) bar="$(mktemp -d)/registratie.bar"; build_flowable_bar "$bar"; populate rr-fl-bpmn "$bar" ;;
|
||||
fl) d="$(mktemp -d)"; stage_flowable_workflows "$d"; populate rr-fl-bpmn "$d/." ;;
|
||||
*) echo "unknown seed key: $key" >&2; exit 2 ;;
|
||||
esac
|
||||
done
|
||||
|
||||
Reference in New Issue
Block a user