-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#51 Add jpms module-info using Multi-Release jar #59
Conversation
Have you given any thought to migrating to new jakarta.inject / jakarta.annotation-api? It might be good time to do the migration while you are introducing JPMS. |
I did a little bit. jakarta.inject uses Automatic-Module-Name in the manifest.
Well I'm still learning but where I'm at at the moment is that I think it is ok for some modules to be "unnamed" ones. My working theory is that unnamed modules are ok in the case that:
As I see it right now, both javax.inject and java.annotation-api match this description (and my example jpms app is fine with them as they are). So right now if I was doing a full jpms app those modules are actually fine to use as is. I currently don't see anything to gain from say forking and making a jpms version of them (some people have done this) or moving to say jakarta.inject (even if they had a module-info which they don't). Hmmm. |
… brought in transitively
Part of my thought process for suggesting a migration to the new 2.x jakarta.inject + jakarta.annotation-api versions are two-fold:
Anyway, that was just part of my thinking at the moment (while reviewing our internal projects and determining how best to migrate them from Guice to this library). |
Maybe, although with this change it still supports java 8 and classpath. This change doesn't demand anything from it's users per say. It's ready for java modules but the majority are still going to be classpath for a while I'm suspecting.
Well it would. What I have in my mind is that there might literally be 2 changes to go in with: Once those are in this library could be very stable and literally only need bug fixes. So my thinking at the moment is to get to there ... be nice and stable and boring ... wait for demand to go to jakarta.inject. Ideally the only change after A) and B) is ... user demand to migrate to jakarta.inject (from javax.inject). |
Yep, that probably makes the most sense. I tend to think too big sometimes :). |
Although maybe we could/should have both by maintaining 2 branches - a branch for javax.inject based dependencies and a branch for jakarta.inject dependencies. My situation sounds similar with existing Guice, HK2 (Jersey) and Spring - and the migration is not always full replacement [of Guice] but where there is co-existence moving towards replacement over time. Now with co-existence I think it would have been nicer/easier to use Plan
Developers can then choose version 2.0 (javax.inject) or 3.0 (jakarta.inject) |
That sounds like it could be workable plan. It probably wouldn't be too difficult to keep any changes in sync between 2.x branch & 3.x branch, since I think the main difference would just be a search/replace of javax.inject => jakarta.inject & javax.annotation => jakarta.annotation. |
No description provided.