Bundlise our api jars to be OSGi-friendly

13 views
Skip to first unread message

Emily Jiang

unread,
Sep 1, 2017, 6:24:59 PM9/1/17
to Eclipse MicroProfile
I have done the necessary work to bundlise all of the MP 1.2 candidates: Config 1.1, FT1.0, Health, JWT and Metrics. For all other repos, you can use the same structure as these projects with all the infrastructure files, you will be fine. 
1. Each package needs to have package-info.java
2. need to have bnd.bnd
3. all the necessary plugins in the pom.xml - refer to one of the above projects listed

In order to verify whether you have done the right thing, open up the MANIFEST.MF in your api jar and look whether all the packages were exported correctly.

e.g.  
Manifest-Version: 1.0
Bundle-License: Apache License, Version 2.0
Bundle-SymbolicName: org.eclipse.microprofile.fault.tolerance
Built-By: Emily
Bnd-LastModified: 1504300095241
Bundle-ManifestVersion: 2
Import-Package: javax.enterprise.util;version="[1.1,2)",javax.intercep
 tor;version="[1.2,2)"
Require-Capability: osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=1.8))"
Tool: Bnd-3.4.0.201707252008
Export-Package: org.eclipse.microprofile.faulttolerance;version="1.0";
 uses:="javax.enterprise.util,javax.interceptor",org.eclipse.microprof
 ile.faulttolerance.exceptions;version="1.0"
Bundle-Name: MicroProfile Fault Tolerance Bundle
Bundle-Version: 1.0.0.201709012108
Created-By: 1.8.0 (IBM Corporation)
Build-Jdk: 1.8.0

Thanks
Emily
Reply all
Reply to author
Forward
0 new messages