Skip to content

refactor: align the remote, operaton-embedded, fullstack and vanillabp examples - #108

Merged
emaarco merged 3 commits into
mainfrom
emaarco/align-remaining-drift
Nov 5, 2026
Merged

emaarco merged 3 commits into
mainfrom
emaarco/align-remaining-drift

Conversation

@emaarco

@emaarco emaarco commented Nov 5, 2026 •

Copy link
Copy Markdown
Member

Why

After #106, 286 paths (466 copies) were still listed under differs as "to be aligned". Most of them sat in four examples: the two remote examples, operaton-embedded, fullstack-cibseven-embedded and zeebe-vanillabp. This change aligns what was accidental there and records the one deliberate difference, zeebe-vanillabp's aggregate-based use cases.

What

  • cibseven-remote and operaton-remote: the Java TestObjectBuilder now has the canonical API, and the application, domain, REST and outbound tests, ports, services and controllers that only differed by style are copied from the embedded examples. JSpecify is dropped from the example-service, where it is no longer needed; the generated engine client still uses it.
  • operaton-embedded: tests move from process/, process/util/, process/model/, architecture/, openapi/ and actuator/ to the packages its siblings use (adapter/process/…, adapter/inbound/rest/, the root package). The pitest excludes, AGENTS.md, skills, agents, ADR-0004 and twelve Bruno scenarios follow.
  • operaton-process-engine-api: ArchitectureTest moves to the root package, with its pitest exclude and AGENTS.md command updated.
  • fullstack-cibseven-embedded: Bruno scenario folders are renumbered like the other examples (06-list-and-inbox → 07-list-and-inbox, 07-alternative-declined → 08-…, 08-invalid-request → 09-…, 09-alternative-via-tasklist → 10-…), and the scenarios are identical to cibseven-embedded's. The ADR numbering stays as it is.
  • zeebe-vanillabp keeps its own shape on purpose: use cases receive the workflow aggregate, without a repository lookup or @Transactional. drift.yml records this with a reason for the 54 affected files, and the code around it is aligned with zeebe-native (tests, comments, ports, services, controllers, Bruno). Its tests gain the "fails for an unknown application" cases from zeebe-native.
  • Shared test classes now carry the union of their meaningful cases in every example of the language (engine-specific tests within their engine family): "fails for an unknown application" service tests, missing-field and null-field request validation, the alternative-found flag, persistence with order and contract, task inbox without business key, stronger unknown-application checks; the assertions dropped while aligning the remote examples (verify/confirmVerified, problem+json) are back. zeebe-native gains the inbox and dealer-outage process tests of zeebe-process-engine-api.
  • drift.yml and drift.lock.yml are updated: stale and moved entries are removed, and the new reasons are added.

Verification

  • npm run drift: 12 examples in step, 4691 locked copies (was 4473); about 82 % of all non-Dependabot files are identical and locked. Copies still listed as "to be aligned" dropped from 466 to about 260.
  • npm test, npm run generate:check and scripts/check-owner.sh pass.
  • All 21 variants built with all tests, one after another, with Testcontainers on Podman (./mvnw -B verify for Java, ./gradlew build for Kotlin). openapi/openapi.json and the generated process APIs are unchanged in every example.
  • Not run: the Bruno scenarios (they need the full stack) and mutation testing (nightly only).

Out of scope / Follow-ups

  • zeebe-vanillabp's SelectAlternativeUseCase does not reject alternativeFound=true without a bikeId (202 instead of the 400 the other examples return). Changing it is a business decision.
  • Behaviour gaps found while fanning out tests (production code unchanged): zeebe-native, zeebe-process-engine-api and temporal-native order a second bike or issue a second contract when a task is delivered again (zeebe-vanillabp guards against it); fullstack's BikeDealerAdapter has no BIKE-FAIL incident-demo bike; operaton-remote's Java RemoteLeasingProcessAdapter does not check for a task without an id.
  • About 171 paths remain under "to be aligned", mainly domain/application/test code, ADRs and agent texts.

@emaarco
emaarco force-pushed the emaarco/align-remaining-drift branch from 972cf3e to ece92fb Compare November 5, 2026 12:38
…p examples

Aligns the remaining accidental drift: the remote examples share the canonical test builder, tests, ports and services; operaton-embedded and operaton-process-engine-api move their tests to the packages their siblings use; fullstack renumbers its Bruno scenarios like the other examples; zeebe-vanillabp keeps its aggregate-based use cases (now recorded in drift.yml) and aligns everything around them.
Every shared test class now carries the union of its meaningful cases in all examples of its language (engine-specific tests within their engine family), and the assertions dropped while aligning the remote examples are back.
@emaarco
emaarco force-pushed the emaarco/align-remaining-drift branch from a3239ee to 9ac8751 Compare November 5, 2026 14:18
@emaarco
emaarco enabled auto-merge (squash) November 5, 2026 14:18
@emaarco
emaarco merged commit 49fe064 into main Nov 5, 2026
61 checks passed
@emaarco
emaarco deleted the emaarco/align-remaining-drift branch November 5, 2026 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant