Skip to content

[#60] Add a deterministic explicit JPMS descriptor - #122

Draft
peter-lawrey wants to merge 4 commits into
feat/Zero-Allocation-Hashing-60-review-pr-107-for-compatibility-cifrom
feature/60-explicit-jpms-module
Draft

[#60] Add a deterministic explicit JPMS descriptor#122
peter-lawrey wants to merge 4 commits into
feat/Zero-Allocation-Hashing-60-review-pr-107-for-compatibility-cifrom
feature/60-explicit-jpms-module

Conversation

@peter-lawrey

@peter-lawrey peter-lawrey commented Aug 21, 2026

Copy link
Copy Markdown
Member

Purpose

Repository-owned continuation of #107, stacked on #119 while that PR awaits its required approval. The original #107 commits are retained unchanged in this branch, including Benjamin Marwell's authored commit cdbdc5060cddb1373a86a1575445b68f1b1d08c0.

After #119 merges, retarget this PR to develop and merge it with a merge commit so the original commit graph and attribution remain intact.

What changed relative to #107

  • Retains [#60] Add JPMS module descriptor, add Maven IT #107's hand-authored module net.openhft.hashing descriptor, multi-release layout, class-path consumer, and module-path consumer.
  • Replaces the JDK [9,) production compilation profile with ModiTect 1.3.0.Final during package.
  • A Java 8 Maven build now always adds META-INF/versions/9/module-info.class; descriptor presence no longer depends on the JDK running Maven.
  • Retains [#60] Publish a stable JPMS automatic module name #119's Automatic-Module-Name: net.openhft.hashing and packaged-JAR integration test.
  • Verifies the packaged descriptor is Java 9 bytecode even when Maven runs on Java 8.
  • Strengthens the modular consumer to assert the module is named and non-automatic, exports only net.openhft.hashing, and has a non-static requires jdk.unsupported.
  • Skips only the Java 9+ modular consumer when Maven itself runs on Java 8; the ordinary consumer and packaged descriptor checks still run.

Validation

Java 8 build

JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64 mvn -B clean verify

  • 14,901 unit tests passed, 12 skipped.
  • Both packaged-JAR integration assertions passed.
  • Class-path consumer passed; modular consumer was correctly skipped due to the Java 8 runtime.
  • Javadocs and licence check passed.

Canonical Java 8-built JAR SHA-256: f629250a02248de8138084e65feac897710fd55d6f0630a397ae6599b1c319ab.

Exact Java 8-built JAR

  • Java 8 class-path consumer: passed.
  • Java 25 class-path consumer: passed (with the expected terminal-deprecation warning for sun.misc.Unsafe).
  • Java 25 module-path consumer: passed and observed explicit module net.openhft.hashing.
  • jar --validate: passed.
  • jar --describe-module --release 9: exports net.openhft.hashing; requires mandated java.base and jdk.unsupported.

Java 25 build

JAVA_HOME=/usr/lib/jvm/java-25-openjdk-amd64 mvn -B clean verify

  • Both 14,901-test executions passed.
  • Both packaged-JAR assertions passed.
  • Both class-path and explicit-module Invoker consumers passed.
  • Javadocs and licence check passed.

Authorship and line-survival audit

  • PR [#60] Add JPMS module descriptor, add Maven IT #107's remote head remains 0bfbe9692e9b4c5d937e64f6569815c4c0d0d78f.
  • Benjamin Marwell's commit remains exactly cdbdc5060cddb1373a86a1575445b68f1b1d08c0, with author Benjamin Marwell <bmarwell@apache.org> and GitHub author @bmarwell.
  • Both commits are unchanged ancestors of this branch through merge commit b84125e0e04efd09b9ffbcec5e2537f169f4645f.
  • Across the final [#60] Add a deterministic explicit JPMS descriptor #122 + [#60] Complete JPMS runtime compatibility through Java 25 #123 stack, 345 of the 372 lines added by [#60] Add JPMS module descriptor, add Maven IT #107 survive unchanged and still blame to Benjamin. The other 27 are the 26 JDK-dependent packaging lines replaced in pom.xml and the one corrected integration-test documentation sentence described below.
  • The seven-line production descriptor remains wholly attributed to Benjamin.
  • The modular consumer's original 41 lines remain attributed to Benjamin; later descriptor assertions only add lines.
  • The original simple consumer (90 lines), its POM (42), its Invoker properties (2), the modular consumer POM (42), modular module-info.java (9), settings (6), and the original modular Invoker properties (2) remain attributed to Benjamin.
  • Of [#60] Add JPMS module descriptor, add Maven IT #107's pom.xml additions, the multi-release manifest configuration and Maven Invoker integration remain attributed to Benjamin (39 surviving lines).
  • The replaced pom.xml lines are specifically the global release property, JDK-conditional compile-java9 execution, and bundle Include-Resource wiring. Those lines made descriptor presence depend on the Maven JDK and therefore had to be replaced by the deterministic ModiTect mechanism.
  • Stage 3 replaces one sentence in [#60] Add JPMS module descriptor, add Maven IT #107's integration-test README because it stated that sun.nio.ch could not be accessed, while the preserved direct-buffer fast path deliberately accesses it through a documented --add-exports option. All other original README lines retain Benjamin's attribution.
  • No commit introduced by this continuation contains a Claude or Anthropic authorship trailer or attribution. Pre-existing shared base history is unchanged.
  • git diff --check passed.

Scope

Part of #60, Stage 2. This establishes deterministic explicit-module packaging. Direct-buffer/internal-API hardening and the broader Java 25 runtime-path matrix belong to Stage 3.

Copy link
Copy Markdown
Member Author

@bmarwell GitHub cannot add you as a formal requested reviewer because it reports that review requests are limited to repository collaborators, but your review is warmly invited. This continuation retains your original commit and the full #107 head unchanged in its ancestry.

@bmarwell

Copy link
Copy Markdown

It is totally fine as a start

@tgd
tgd removed request for james-mcsherry and tgd August 26, 2026 18:08
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