Replace spring-bundlor plugin with maven-bundle-plugin #816

Closed
balazs-zsoldos opened this Issue Jun 19, 2014 · 5 comments

Comments

Projects
None yet
2 participants
@balazs-zsoldos
Contributor

balazs-zsoldos commented Jun 19, 2014

Spring bundlor plugin is not an active project since 2010. Spring decided not to support OSGi.

maven-bundle-plugin uses bnd that is embedded into every development tools that support OSGi. This means that the MANIFEST generation will be the same as with other development tools. Some notes about maven-bundle-plugin:

  • if the dependency is optional, maven-bundle-plugin adds Import-Package constraint as optional to the MANIFEST
  • maven-bundle-plugin has M2E support. In case we develop with eclipse, we can deploy the target/classes folder from Eclipse to the OSGi container directly
  • maven-bundle plugin generates version ranges for Import-Packages in the way that the next major version change is excluded. E.g.: If the version of the package in the dependency is 1.2.1, the MANIFEST header will contain [1.2.1,2).

This issue depends on #812 and #814 as the same pom.xml files should be changed to achieve the goal. I will create a pull request after those issues are closed. The pull request will contain the followings::

  • maven-bundle-plugin entry in querydsl-root
  • maven-bundle-plugin entry in querydsl-core and querydsl-sql instead of spring bundlor

If it is necessary, I can do the changes in other modules as well. However, I cannot test the effect changes in live OSGi environment. The main difference will be that the version of Imported packages will have boundaries.

@timowest

This comment has been minimized.

Show comment
Hide comment
@timowest

timowest Jun 19, 2014

Member

The proposed changes should definitely be tested by someone who uses OSGI. Unfortunately I also don't use OSGI.

Member

timowest commented Jun 19, 2014

The proposed changes should definitely be tested by someone who uses OSGI. Unfortunately I also don't use OSGI.

@balazs-zsoldos

This comment has been minimized.

Show comment
Hide comment
@balazs-zsoldos

balazs-zsoldos Jun 19, 2014

Contributor

I use OSGi all the time. However, I we decided not to use JPA anymore and we have never used JDO. Therefore I can test only querydsl-core and querydsl-sql.

Making an Import-Package optional possible with the spring bundlor plugin as well, but in that case the packages have to be defined manually (more configuration in the pom.xml).

I made some tests where I switched the plugin from bundlor to maven-bundle-plugin only in the core and sql modules and it worked pretty well. Question is: May I switch the plugins only in these two modules?

Contributor

balazs-zsoldos commented Jun 19, 2014

I use OSGi all the time. However, I we decided not to use JPA anymore and we have never used JDO. Therefore I can test only querydsl-core and querydsl-sql.

Making an Import-Package optional possible with the spring bundlor plugin as well, but in that case the packages have to be defined manually (more configuration in the pom.xml).

I made some tests where I switched the plugin from bundlor to maven-bundle-plugin only in the core and sql modules and it worked pretty well. Question is: May I switch the plugins only in these two modules?

@timowest

This comment has been minimized.

Show comment
Hide comment
@timowest

timowest Jun 19, 2014

Member

You can switch all of them. We can compare the resulting manifests.

Member

timowest commented Jun 19, 2014

You can switch all of them. We can compare the resulting manifests.

@balazs-zsoldos

This comment has been minimized.

Show comment
Hide comment
@balazs-zsoldos

balazs-zsoldos Jun 23, 2014

Contributor

Up-to-date information: Eclipse Virgo project seems to be alive and they continued to work on spring-bundlor-plugin. However, the plugin itself is not uploaded to maven-central. There is a dependency that has maven in its name, but it has jar packaging and not plugin.

I still suggest to use maven-bundle-plugin as it is available at maven-central and it has a bigger community. I will continue in this way.

Contributor

balazs-zsoldos commented Jun 23, 2014

Up-to-date information: Eclipse Virgo project seems to be alive and they continued to work on spring-bundlor-plugin. However, the plugin itself is not uploaded to maven-central. There is a dependency that has maven in its name, but it has jar packaging and not plugin.

I still suggest to use maven-bundle-plugin as it is available at maven-central and it has a bigger community. I will continue in this way.

@timowest

This comment has been minimized.

Show comment
Hide comment
@timowest

timowest Jun 29, 2014

Member

Released in 3.4.1

Member

timowest commented Jun 29, 2014

Released in 3.4.1

@timowest timowest closed this Jun 29, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment