Skip to content

feat(verification): add Java support for Docker-based verification#263

Merged
ekarademir merged 1 commit into
accordproject:mainfrom
apoorv7g:Java-CI
Jul 13, 2026
Merged

feat(verification): add Java support for Docker-based verification#263
ekarademir merged 1 commit into
accordproject:mainfrom
apoorv7g:Java-CI

Conversation

@apoorv7g

Copy link
Copy Markdown
Contributor

Add Java to Docker and local verification

This pull request expands verification to include Java alongside the existing compiled targets (TypeScript, Rust, and C#). Generated Java is compiled with javac using Jackson annotations on the classpath, matching what the Java visitor emits today.

Changes

  • Added Java to the Docker verification matrix with eclipse-temurin:17-jdk-alpine and javac as the compile step
  • Created verification/docker/java/Dockerfile and verification/docker/java/entrypoint.sh to generate and compile Java from the verification corpus
  • Registered Java in verification/docker/targets.json with CLI target Java and type compiled
  • Added verify:docker:java to package.json and included java in scripts/verification/docker-run.js
  • Extended .github/workflows/verify-codegen.yml CI matrix with the java target
  • Added test/verification/java.compile.test.js to generate Java locally and verify compilation with javac
  • Downloads jackson-annotations from Maven Central on first local test run and during Docker image build
  • Updated test/verification/cases.js with a per-case skip for hr_integration when scalar map key/value types are not emitted as Java classes
  • Updated verification/corpus/manifest.json so the metamodel case runs for Java in Docker (C# remains skipped)

Flags

  • Generated Java references Jackson annotation types (@JsonTypeInfo, @JsonIgnoreProperties, and others), so javac requires jackson-annotations on the classpath
  • The Jackson JAR is not committed; it is downloaded into verification/templates/ on first local test run (gitignored) and fetched in the Docker image at build time
  • hr_integration is skipped in local Mocha tests because the Java visitor does not emit scalar types such as SSN and Time referenced by map declarations
  • npm run verify:docker:java requires a running Docker daemon (for example Docker Desktop on Windows)

Author Checklist

  • Ensure you provide a DCO sign-off for your commits using the --signoff option of git commit.
  • Vital features and changes captured in unit and/or integration tests
  • Commits messages follow AP format
  • Extend the documentation, if necessary
  • Merging to main from fork:branchname

- Introduced Java as a new target in the Docker verification setup.
- Updated package.json, Dockerfiles, and entrypoint scripts to support Java code generation and compilation.
- Added tests for verifying Java compilation, including skip reasons for specific cases.
- Enhanced the verification manifest to include Java as a target.

This commit expands the verification capabilities to include Java, ensuring a consistent environment for testing and validation.

Signed-off-by: Apoorv <130035517+APOORV7G@users.noreply.github.com>
@DianaLease
DianaLease requested a review from ekarademir July 13, 2026 13:53
@ekarademir
ekarademir merged commit ecb7718 into accordproject:main Jul 13, 2026
18 checks passed
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.

2 participants