karaf-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Achim Nierbeck <bcanh...@googlemail.com>
Subject Re: deploying a war with dependencies in bundled jars
Date Sat, 03 Jan 2015 13:20:18 GMT
Is it the war file or one of the others that doesn't resolve?
Does the war actually contain the generated manifest?
How do you reference that package, is it included in your Import-Package of
the manifest
is there actually a bundle available that exports it?

regards, Achim


2015-01-02 22:05 GMT+01:00 jefoy1101 <jefoy1101@gmail.com>:

> Hi Achim,
>
> I already have these on my dependency
>
> <dependencies>
>                 <dependency>
>                         <groupId>org.osgi</groupId>
>                         <artifactId>org.osgi.core</artifactId>
>                         <version>${osgi.version}</version>
>                         <scope>provided</scope>
>                 </dependency>
>                 <dependency>
>                         <groupId>com.pinsight.adgateway</groupId>
>                         <artifactId>domain</artifactId>
>                         <version>3.0.1-SNAPSHOT</version>
>                         <scope>provided</scope>
>                 </dependency>
>                 <dependency>
>                         <groupId>com.pinsight.adgateway.provider</groupId>
>                         <artifactId>provider</artifactId>
>                         <version>3.0.1-SNAPSHOT</version>
>                         <scope>provided</scope>
>                 </dependency>
>                 <dependency>
>                         <groupId>com.pinsight.adgateway.client</groupId>
>                         <artifactId>client-7UL</artifactId>
>                         <version>3.0.1-SNAPSHOT</version>
>                         <scope>provided</scope>
>                 </dependency>
> <dependencies>
>
> and have this on the plugings section
>
> <plugin>
>                                 <groupId>org.apache.felix</groupId>
>
> <artifactId>maven-bundle-plugin</artifactId>
>                                 <extensions>true</extensions>
>                                 <configuration>
>                                         <supportedProjectTypes>
>
> <supportedProjectType>jar</supportedProjectType>
>
> <supportedProjectType>bundle</supportedProjectType>
>
> <supportedProjectType>war</supportedProjectType>
>                                         </supportedProjectTypes>
>                                         <instructions>
>
> <Bundle-SymbolicName>${bundle.symbolicName}</Bundle-SymbolicName>
>
> <Bundle-Version>${project.version}</Bundle-Version>
>                                                 <Import-Package>
>                                                         *;
> resolution:=optional
>                                                 </Import-Package>
>
> <Export-Package>com.pinsightmedia.*,!*</Export-Package>
>                                                 <Bundle-Classpath>
>                                                         WEB-INF/classes
>                                                 </Bundle-Classpath>
>
> <Web-ContextPath>agwar</Web-ContextPath>
>                                                 <Embed-Dependency>*;
> artifactId=!org.osgi.compendium;
>                                                         scope=compile;
> type=!pom; inline=true</Embed-Dependency>
>
> <Embed-Transitive>true</Embed-Transitive>
>                                                 <_removeheaders>
>                                                         Include-Resource,
>                                                         Private-Package,
>                                                         Embed-Dependency,
>                                                         Embed-Transitive,
>                                                         Ignore-Package
>                                                 </_removeheaders>
>                                         </instructions>
>                                 </configuration>
>                                 <executions>
>                                         <execution>
>                                                 <id>generate-manifest</id>
>
> <phase>process-classes</phase>
>                                                 <goals>
>
> <goal>manifest</goal>
>                                                 </goals>
>                                         </execution>
>                                 </executions>
>                         </plugin>
>                         <plugin>
>                                 <artifactId>maven-war-plugin</artifactId>
>                                 <configuration>
>                                         <archive>
>
>
> <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
>                                         </archive>
>                                 </configuration>
>                         </plugin>
>
>
> SO I have my etc/mycnfg.cfg that actually install all the jars and put it
> in
> karaf as bundles, once karaf started they are all being installed and then
> I
> will just have to copy and paste my war file to the deploy folder
>
> but still getting the noclassfound error from one of the dependency
>
> Caused by: java.lang.ClassNotFoundException: <ClassName> not found by
> com.XXXX.framework [110]
>
>
>
>
> --
> View this message in context:
> http://karaf.922171.n3.nabble.com/deploying-a-war-with-dependencies-in-bundled-jars-tp4037488p4037544.html
> Sent from the Karaf - User mailing list archive at Nabble.com.
>



-- 

Apache Member
Apache Karaf <http://karaf.apache.org/> Committer & PMC
OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> Committer &
Project Lead
blog <http://notizblog.nierbeck.de/>
Co-Author of Apache Karaf Cookbook <http://bit.ly/1ps9rkS>

Software Architect / Project Manager / Scrum Master

Mime
View raw message