Saturday, March 28

peaberry - EclipseCon slides now available

My EclipseCon talk on peaberry seems to have been well received, although I think it would have been even better if I'd reduced the technical content to allow time for more questions. I always find short talks harder to plan than long talks, and this was a good learning experience.

If you missed the talk you can either view it on gPublication or download the original presentation.

Of course hearing from my boss that he was closing our company the night before didn't really help. But I'm glad I got the chance to visit EclipseCon one more time and expand my network, which will come in useful for my upcoming job search.

So if you know of any companies interested in hiring someone with good Java, OSGi, and Maven skills... let me know :)

Thursday, March 5

maven-bundle-plugin 2.0.0 released!

The Apache Felix team is pleased to announce the release of maven-bundle-plugin 2.0.0

This release uses the latest bndlib (0.0.311) which requires you to build with a Java5 JDK. You can continue to target earlier JVMs while building with a Java5 or later JDK by setting the source and target levels in the maven-compiler-plugin configuration.

Here is the list of issues fixed in this release:

Bug

  • [FELIX-545] - Export-Package version inconsistencies.
  • [FELIX-546] - Import-Package version inconsistencies.
  • [FELIX-549] - Import-Package should not include "snapshot" from snapshot dependencies
  • [FELIX-660] - "Class in different directory than declared" error when bundle classes in a directory other than bundle root
  • [FELIX-677] - Parser throws error when DynamicImport-Package contains attributes
  • [FELIX-699] - manifest goal does not interprete _include instruction correctly
  • [FELIX-782] - Manifest goal ignores version attribute specified in _exportcontents
  • [FELIX-807] - conversion of JAR into bundle fails if there are classes is the default name space
  • [FELIX-831] - bndlib unnecessary modifies valid OSGi Bundle-Version numbers (update to bndlib 0.0.293)
  • [FELIX-843] - Regression: BND 0.0.295 does not augment Ignore-Package with excluded import packages
  • [FELIX-850] - Wrong symbolic name computed when groupId is a single segment string.
  • [FELIX-864] - A wrong symbolic name is calculated if artifactId starts with lastGroupIdSegment-.
  • [FELIX-899] - Version attribute missing from Import-Package on provided dependencies
  • [FELIX-907] - Regression in latest BND code: negated exports are applied to private packages

Improvement

  • [FELIX-684] - Enable excludeDependencies to check groupId, version, etc. rather than only artifactId
  • [FELIX-806] - changing the internal configuration of the archive plugin doesn't seem to be possible
  • [FELIX-941] - Support singleton & fragment-attachment directive generation

New Feature

  • [FELIX-912] - Improve default Export-Package / Private-Package settings by scanning the project source
A quick bundle example using the classic Maven quickstart project:

  mvn archetype:create -DgroupId=com.mycompany.app -DartifactId=my-app

# edit the pom.xml, change packaging from jar to bundle and add:

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.felix</groupId>
        <artifactId>maven-bundle-plugin</artifactId>
        <version>2.0.0</version>
        <extensions>true</extensions>
      </plugin>
    </plugins>
  </build>

  mvn clean install
# you should now have a valid OSGi bundle

plugin docs: http://felix.apache.org/site/apache-felix-maven-bundle-plugin-bnd.html
plugin FAQ: http://felix.apache.org/site/apache-felix-bundle-plugin-faq.html
bnd docs: http://www.aqute.biz/Code/Bnd

--
Regards, the Apache Felix team