restlet-framework-java icon indicating copy to clipboard operation
restlet-framework-java copied to clipboard

Drop support of OSGi

Open thboileau-git opened this issue 1 month ago • 0 comments

Why drop it

  • Ecosystem shift: OSGi use has shrunk a lot. Most users run Spring Boot, Quarkus, plain JARs or containers. The main holdouts are Eclipse/Equinox-based products and Karaf/Felix deployments.
  • JPMS overlap: module-info.java was just added. Keeping both is hard (automatic and split packages, Import-Package vs requires, service-loading differences). Several extension libraries aren't OSGi-friendly either, which is what the Woodstox hack is for.
  • Cost: extra manifest metadata, a classloading-specific code path, and bundle testing that CI almost certainly doesn't do. Untested OSGi support tends to be broken in practice anyway.
  • Timing: 3.0 is already a breaking release with a raised Java baseline, so removing it now costs the least.

Drop it in 3.0:

  • Delete the Activator, the osgi.core dependency and the requires static osgi.core; line.
  • Simplify XmlFactoryProvider to plain ServiceLoader.
  • Add a Breaking changes entry in changes.md saying OSGi support was removed, and pointing OSGi users to 2.x.

thboileau-git avatar Oct 17 '26 09:10 thboileau-git