Skip to content

Harden bundle constraints between Xtext bundles #2892

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

Merged
merged 5 commits into from
Jan 8, 2024
Merged

Conversation

szarnekow
Copy link
Contributor

@szarnekow szarnekow commented Jan 7, 2024

Also:

  • Export versioned packages throughout the code base
  • Some fixes to MergableManifest2
  • Added a Java based script to bump the Xtext version honoring the Manifest semantics without regex foo
  • Aligned version of xtext.logging fragment with version number of Xtext rather than the version number of the host bundle

Since we don't do any semantic versioning in Xtext, it's safest to
assume that all bundles require always the lastest version of their
peers.

Signed-off-by: Sebastian Zarnekow <sebastian.zarnekow@gmail.com>
This should allow clients to use import-package instead of
require-bundle for their Xtext dependencies
Signed-off-by: Sebastian Zarnekow <sebastian.zarnekow@gmail.com>
Signed-off-by: Sebastian Zarnekow <sebastian.zarnekow@gmail.com>
@szarnekow szarnekow added this to the Release_2.34 milestone Jan 7, 2024
Signed-off-by: Sebastian Zarnekow <sebastian.zarnekow@gmail.com>
@szarnekow szarnekow self-assigned this Jan 8, 2024
@szarnekow szarnekow merged commit 316daf7 into main Jan 8, 2024
Copy link
Contributor

@LorenzoBettini LorenzoBettini left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for being late ;)

I think the updates to the xtext.logging version are wrong: that is a fragment that has to match the version of the log4j bundle. At least, that's what @cdietrich told me during the porting to the monorepo.

Moreover, I don't remember the rationale for this explicit versioning. You told me something about future Xtext OSGI enhancements; it's related to that, isn't it?

@@ -79,7 +79,7 @@
<requirement>
<type>eclipse-plugin</type>
<id>org.eclipse.xtext.logging</id>
<versionRange>1.2.24</versionRange>
<versionRange>${xtextVersion}</versionRange>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see my comment above about the xtext.logging version

@szarnekow
Copy link
Contributor Author

Sorry for being late ;)

No worries.

The rationale is that Xtext bundles strictly depend on each other and therefore the OSGI metadata should reflect that. So far we didn't provide this information as part of the Manifest which could have led to wirings in an OSGI container that are not working.

Exporting packages with proper versions will help users who try to be good OSGI citizens and use import-package rather than require-bundle.

@szarnekow szarnekow deleted the sz_bundleConstraints branch January 8, 2024 09:34
@cdietrich
Copy link
Contributor

This is also new to me

@szarnekow
Copy link
Contributor Author

This is also new to me

You mean the versioning of fragments?

@cdietrich
Copy link
Contributor

cdietrich commented Jan 8, 2024

yes we always had the host bundle version there. and i dont know why

@szarnekow
Copy link
Contributor Author

yes we always had the host bundle version there. and i dont know why

I think back then we didn't know better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants