-
Notifications
You must be signed in to change notification settings - Fork 93
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
Embed the google cache dependency in the bundle #1703
base: main
Are you sure you want to change the base?
Conversation
c617f2a
to
1652abe
Compare
Can you please clarify what is "the bundle" here? Is it the uber-jar? |
If you run the build you get these artifacts (as of today):
|
Guava is known as a bit "problematic" dependency, as lemminx only uses guava-cache, this can be embedded in the bundle and be made embedded package. This changes the used felix-bundle to bnd-maven-plugin with the conditionalpackage to include the caching api in the generated bundle Signed-off-by: Christoph Läubrich <[email protected]>
1652abe
to
534382a
Compare
I would rather not touch the default artifact/bundle as the proposal is adding some complexity while the artifact/bundle is itself working well. |
The idea is to make the dependency requirements of the bundle less a concern and at some point make the uber-jar not required for usual deployments especially the ones you mentioned here
So even though google-cache is OSGi it falls in the first category and always produces some interoperability problems if someone uses a quite narrow range. As it is not part of any public API its a good candidate for embedding (see rationale here) and as everything is automatically handled by BND in this case I don't see much complexity (for the developers/users)
Can you give examples where lemminx bundle is actually used inside an OSGi deployment?
The problem is that the uber-jar includes much more I also found here: that even a very simple approach requires never maven, maybe even never build JVM, even though it might be solvable. So currently I somehow tend to maybe make the "real" bundle more easily deployable and less exposed to some kinds of dependency issues (e.g. embedd as much as possible at that stage already). |
Guava is known as a bit "problematic" dependency, as lemminx only uses guava-cache, this can be embedded in the bundle and be made embedded package.
This changes the used felix-bundle to bnd-maven-plugin with the conditionalpackage to include the caching api in the generated bundle.
FYI @mickaelistria I just choose this a startingpoint because with
this type does not appear in any public (exported) API anymore, if it could be agreed that this is a way to go I'll try to identify other possible types to embed as well.