Skip to content

Add OSGi metadata to the manifest#485

Merged
mpkorstanje merged 1 commit intomainfrom
add_osgi_manifest
Oct 10, 2025
Merged

Add OSGi metadata to the manifest#485
mpkorstanje merged 1 commit intomainfrom
add_osgi_manifest

Conversation

@laeubi
Copy link
Copy Markdown
Contributor

@laeubi laeubi commented Oct 2, 2025

This pull request updates the Maven project configuration in java/pom.xml. The main changes are a version bump for the parent POM and the addition of new build plugins to enhance the project's build process.

Dependency and build configuration updates:

  • Updated the parent POM version from 4.3.8 to 4.3.9-SNAPSHOT to track the latest snapshot version.
  • Added the bnd-maven-plugin for OSGi bundle support and the maven-jar-plugin with custom manifest file configuration to the build plugins section.

The summary output is

[INFO] The Bundle-SymbolicName is: io.cucumber.gherkin
[INFO] 36.0.1.SNAPSHOT
[INFO] It has 12 requirements:
[INFO]  ✓ Import-Package: io.cucumber.messages; version="[30.1.0,31.0.0)" (provided by io.cucumber:messages:jar:30.1.0)
[INFO]  ✓ Import-Package: io.cucumber.messages.types; version="[30.1.0,31.0.0)" (provided by io.cucumber:messages:jar:30.1.0)
[INFO]  ✓ Import-Package: java.io (provided by the JVM)
[INFO]  ✓ Import-Package: java.lang (provided by the JVM)
[INFO]  ✓ Import-Package: java.lang.invoke (provided by the JVM)
[INFO]  ✓ Import-Package: java.net (provided by the JVM)
[INFO]  ✓ Import-Package: java.nio.charset (provided by the JVM)
[INFO]  ✓ Import-Package: java.nio.file (provided by the JVM)
[INFO]  ✓ Import-Package: java.util (provided by the JVM)
[INFO]  ✓ Import-Package: java.util.function (provided by the JVM)
[INFO]  ✓ Import-Package: java.util.regex (provided by the JVM)
[INFO]  ✓ Import-Package: java.util.stream (provided by the JVM)
[INFO] It provides 1 capabilities:
[INFO]  - Export-Package: io.cucumber.gherkin; bundle-symbolic-name="io.cucumber.gherkin"; bundle-version="36.0.1.SNAPSHOT"; version="36.0.1"; uses:="io.cucumber.messages,io.cucumber.messages.types"

the final manifest looks like this

Manifest-Version: 1.0
Created-By: Maven JAR Plugin 3.4.2
Build-Jdk-Spec: 21
Specification-Title: Gherkin
Specification-Version: 36.0
Implementation-Title: Gherkin
Implementation-Version: 36.0.1-SNAPSHOT
Automatic-Module-Name: io.cucumber.gherkin
Bundle-Description: Gherkin parser
Bundle-Developers: cucumber;email="[email protected]";name="Cucumber Deve
 lopers";organization=Cucumber;organizationUrl="https://github.com/cucum
 ber"
Bundle-DocURL: https://github.com/cucumber/gherkin
Bundle-License: "MIT License";link="https://www.opensource.org/licenses/
 mit-license"
Bundle-ManifestVersion: 2
Bundle-Name: Gherkin
Bundle-SCM: url="git://github.com/cucumber/gherkin.git",connection="scm:
 git:git://github.com/cucumber/gherkin.git",developer-connection="scm:gi
 t:[email protected]:cucumber/gherkin.git",tag=HEAD
Bundle-SymbolicName: io.cucumber.gherkin
Bundle-Version: 36.0.1.SNAPSHOT
Export-Package: io.cucumber.gherkin;uses:="io.cucumber.messages,io.cucum
 ber.messages.types";version="36.0.1"
Import-Package: io.cucumber.messages;version="[30.1,31)",io.cucumber.mes
 sages.types;version="[30.1,31)",java.io,java.lang,java.lang.invoke,java
 .net,java.nio.charset,java.nio.file,java.util,java.util.function,java.u
 til.regex,java.util.stream
Require-Capability: osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=1.8))"


@laeubi laeubi force-pushed the add_osgi_manifest branch from 56abee6 to 7a0b0fc Compare October 10, 2025 17:36
@laeubi laeubi requested a review from mpkorstanje October 10, 2025 17:37
@laeubi laeubi marked this pull request as ready for review October 10, 2025 17:37
@laeubi
Copy link
Copy Markdown
Contributor Author

laeubi commented Oct 10, 2025

@mpkorstanje as the messages where release (many thanks 👍 ) this is now ready to be merged, I updated the description and it shows the new messages bundle is consumed and work as expected:

 ✓ Import-Package: io.cucumber.messages; version="[30.1.0,31.0.0)" (provided by io.cucumber:messages:jar:30.1.0)
 ✓ Import-Package: io.cucumber.messages.types; version="[30.1.0,31.0.0)" (provided by io.cucumber:messages:jar:30.1.0)

for this to work I enlarged the version range in the pom.xml as well.

Comment thread java/pom.xml Outdated
@laeubi laeubi force-pushed the add_osgi_manifest branch from 7a0b0fc to 02ba7e2 Compare October 10, 2025 19:21
@laeubi laeubi requested a review from mpkorstanje October 10, 2025 19:21
@mpkorstanje mpkorstanje merged commit f31021f into main Oct 10, 2025
4 checks passed
@mpkorstanje mpkorstanje deleted the add_osgi_manifest branch October 10, 2025 21:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants