Repository navigation
Add a real JPMS module descriptor: com.github.zrdj.java.identifiers - #16
Merged
Merged
Conversation
The published jar has neither a module-info.class nor an Automatic-Module-Name entry, so a named module that requires it gets the name derived from the jar file, "java.identifiers" - a name in the java.* namespace the JDK reserves for platform modules. tibbots/bots wants to use this library from such a named module. Ship module-info.java with the module name matching the root package, exporting both packages and requiring the four f4b6a3 modules transitively, since Ulid, Tsid, Ksuid, UuidNamespace and UuidLocalDomain appear in the public signatures of Identifiers and Codecs. The version moves to 0.3.0; the decision record explains why. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds
src/main/java/module-info.javadeclaringmodule com.github.zrdj.java.identifiers:exports com.github.zrdj.java.identifiersandexports com.github.zrdj.java.identifiers.codecsrequires transitiveforcom.github.f4b6a3.uuid,.ulid,.tsid,.ksuid, because their types appear in the public API (Ulid,Tsid,Ksuidas return types,UuidNamespace/UuidLocalDomainas parameters). All four declare a stableAutomatic-Module-Namein their manifests.Version goes to 0.3.0.
Why
0.2.1 has neither a descriptor nor
Automatic-Module-Name, so JPMS derivesjava.identifiersfrom the jar file name, which lands in thejava.*namespace the JDK reserves. tibbots/bots#27 wants to useCodecs.UUIDBase62()for the webmail token from a JPMS module. Same fix as ZrdJ/java-properties#18.Decision:
.docs/project/decisions/2026-10-18-real-module-descriptor-instead-of-automatic-name.md.Check
./dev check: 18 tests green.jar --describe-moduleon the 0.3.0 jar shows the module. javac warnsrequires transitive directive for an automatic moduleonce per f4b6a3 dependency; that comes from those jars having no real descriptor.🤖 Generated with Claude Code