RFR: 7903440: JMH: Add automatic module names

Aleksey Shipilev shade at openjdk.org
Fri Sep 8 08:21:05 UTC 2023


On Mon, 20 Feb 2023 18:05:22 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

>> `maven-jar-plugin` is used to add "Automatic-Module-Name" to `MANIFEST.MF` at buildtime. This is the minimum that is needed if you want to use the lib on the module path in a project.
>
> I am actually on the fence with this change. Module names are the part of external API, so picking the correct name is important, as it is supposed to remain stable. This is probably okay for JMH, as we seldom change the API to begin with.
> 
> I assume you wanted to capture the package names as module names? If so, why `org.openjdk.jmh.core` then? There is no package name like that. Can it be `org.openjdk.jmh`, or does it introduce split packages problem downstream?

> Hi @shipilev can you tell me if there is a problem with the PR. Totally fine to change it and continue to work own it bit I would really like to get module names added to JMH ;)

Apologies, I keep getting distracted. 

Part of me do not want to commit to a particular API, even for modules. But I guess it does no harm, and we can plausibly change the automatic module names later if found current ones unfortunate. Even though it would be the API-breaking change.

-------------

PR Comment: https://git.openjdk.org/jmh/pull/90#issuecomment-1711268677


More information about the jmh-dev mailing list