Why the "maven-bundle-plugin" plugin adds some of the "Import-Package" messages in the "META-INF/MANIFEST.MF"
Issue
- The
"MANIFEST.MF"
is created by the apache Felix plugin program. Felix program creates"MANIFEST.MF"
by reading the"Import-Package"
tag. - This is my pom of my TestProject project. There are only 2 entries it for the
"MANIFEST.MF"
file. i.e. component and log4j.
<build>
<defaultGoal>install</defaultGoal>
<plugins>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<version>${maven-bundle-plugin.version}</version>
<extensions>true</extensions>
<configuration>
<instructions>
<Import-Package>
org.apache.activemq.camel.component,
org.apache.log4j,
*
</Import-Package>
<Export-Package>test.project.one</Export-Package>
</instructions>
</configuration>
</plugin>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.5.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
</configuration>
</plugin>
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<version>2.6</version>
<configuration>
<encoding>UTF-8</encoding>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.camel</groupId>
<artifactId>camel-maven-plugin</artifactId>
<version>2.12.0.redhat-610379</version>
</plugin>
</plugins>
</build>
- Yet, while looking at the generated
"MANIFEST.MF"
file, it has many jars listed.
Manifest-Version: 1.0
Export-Package: test.project.one;uses:="javax.jms,org.apache.camel,o rg.springframework.jms.core,com.google.gson,org.apache.log4j,javax.sq
l,org.springframework.jdbc.core,org.apache.camel.component.file,org.a pache.commons.compress.archivers.tar,org.springframework.context.supp
ort,org.apache.camel.builder,org.apache.camel.model,javax.xml.bind"
Bundle-Version: 1.0.0
Build-Jdk: 1.7.0_55
Built-By: mmeandro
Tool: Bnd-1.15.0
Bnd-LastModified: 1408667612600
Bundle-Name: TEST BZ
Bundle-ManifestVersion: 2
Created-By: Apache Maven Bundle Plugin
Import-Package: com.google.gson;version="[2.2,3)",javax.jms;version="[
1.1,2)",javax.mail;version="[1.4,2)",javax.mail.internet;version="[1.
4,2)",javax.sql,javax.xml.bind,javax.xml.bind.annotation,org.apache.a
ctivemq,org.apache.activemq.camel.component;version="[5.9,6)",org.apa
che.activemq.command,org.apache.activemq.pool,org.apache.camel;versio
n="[2.12,3)",org.apache.camel.builder;version="[2.12,3)",org.apache.c
amel.component.file;version="[2.12,3)",org.apache.camel.model;version
="[2.12,3)",org.apache.camel.spring;version="[2.12,3)",org.apache.com
mons.compress.archivers.tar;version="[1.5,2)",org.apache.commons.dbcp
;version="[1.4,2)",org.apache.log4j;version="[1.2,2)",org.springframe
work.context.support,org.springframework.dao,org.springframework.jdbc
.core,org.springframework.jms.core,org.springframework.mail;version="
[3.1,4)",org.springframework.mail.javamail;version="[3.1,4)"
Bundle-SymbolicName: test.project.TestProject
- Where did all the other values for this Import-Package portion of the MANIFEST.MF come from?
Environment
- Fuse ESB
- 7.1.1
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.