Skip to content

Add OSGi manifest headers to JARs #12099

Open
@bdhoine

Description

@bdhoine

Is your feature request related to a problem? Please describe.

The current build of the opentelemetry-java-instrumentation project lacks the necessary OSGi manifest headers in its generated JAR files. This omission prevents the JARs from being used directly as OSGi bundles. To ensure compatibility and ease of integration with OSGi environments, it is important to include the appropriate OSGi headers in the manifest files of these JARs.

Describe the solution you'd like

Modify the build configuration to automatically include the necessary OSGi headers in the manifest files of all JARs produced by this project.

The following headers should be included in the manifest:

  • Bundle-Name: A human-readable name for the bundle.
  • Bundle-SymbolicName: A unique identifier for the bundle.
  • Bundle-Version: The version of the bundle.
  • Export-Package: The packages to be exported for use by other bundles.
  • Import-Package: The packages required by this bundle from other bundles.

Describe alternatives you've considered

No response

Additional context

Adding these headers would significantly enhance the usability of this library in OSGi-based projects, allowing for seamless integration into environments that rely on modularity and dynamic loading of components. It would also align this project with best practices for Java library distribution in modular systems.

Metadata

Metadata

Assignees

No one assigned

    Labels

    contribution welcomeRequest makes sense, maintainers probably won't have time, contribution would be welcomeenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions