Re: Re: cannot run client application using jclient

Benjamin Jailly <[email protected]> Wed, 13 Apr 2011 15:04:13 +0200
Newsgroups gmane.comp.java.objectweb.jonas
Message-ID <[email protected]>
ouuups, forgot to tell you :-)

I tried with both 5.1.5 and 5.2.0.

Benjamin

Le 13 avr. 2011 à 13:48, Guillaume Sauthier a écrit :

> Yeah, what version of JOnAS are you using ? :)
> --G
> 
> 
> Le 13/04/2011 12:48, Benjamin Jailly a écrit :
>> 
>> Hi all,
>> 
>> I have an ear application myEntrepriseApp containing a war, an ejb-jar and a jar client.
>> The ear is built using Maven2. 
>> 
>> Deploying the ear application works fine. The webapp contained in the war is also working properly.
>> 
>> But when I try to run the jar client application, I have the following error:
>> 
>> There was the following exception : null
>> java.lang.NullPointerException
>> 
>>             at org.ow2.jonas.lib.cpmanager.EarClassPathManager.resolveClassPath(EarClassPathManager.java:281)
>> 
>>             at org.ow2.jonas.lib.cpmanager.EarClassPathManager.getResolvedClassPath(EarClassPathManager.java:228)
>> 
>>             at org.ow2.jonas.client.ClientContainer.extractAndAnalyzeEar(ClientContainer.java:1183)
>> 
>>             at org.ow2.jonas.client.ClientContainer.start(ClientContainer.java:421)
>> 
>>             at org.ow2.jonas.client.ClientContainer.main(ClientContainer.java:244)
>> 
>>             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> 
>>             at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>> 
>>             at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>> 
>>             at java.lang.reflect.Method.invoke(Method.java:597)
>> 
>>             at org.ow2.jonas.client.boot.Bootstrap.main(Bootstrap.java:103)
>> 
>> I guess it doesn't find the manifest of the jar client, which is at its good place in the compiled jar (META-INF/MANIFEST.MF).
>> 
>> The command I'm using to launch the jar client is:
>> jclient -nowsgen $JONAS_BASE/deploy/myEntrepriseApp-0.1-SNAPSHOT.ear
>> 
>> 
>> 
>> the pom.xml of the jar client is the following:
>> 
>> 
>> <?xml version="1.0"?>
>> <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
>>     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
>>     <modelVersion>4.0.0</modelVersion>
>>     <parent>
>>         <artifactId>myEntrepriseApp</artifactId>
>>         <groupId>com.test</groupId>
>>         <version>0.1-SNAPSHOT</version>
>>     </parent>
>>     <groupId>com.test</groupId>
>>     <artifactId>myClientApp</artifactId>
>>     <version>0.1-SNAPSHOT</version>
>>     <name> myClientApp</name>
>>     <packaging>jar</packaging>
>>     <dependencies>
>>     </dependencies>
>>     <build>
>>         <plugins>
>>             <plugin>
>>                 <groupId>org.apache.maven.plugins</groupId>
>>                 <artifactId>maven-jar-plugin</artifactId>
>>                 <version>2.3.1</version>
>>                 <configuration>
>>                     <archive>
>>                         <manifest>            
>>                             <mainClass>com.test.Main</mainClass>
>>                             <packageName>com.test</packageName>
>>                         </manifest>
>>                     </archive>
>>                 </configuration>
>>             </plugin>
>>         </plugins>
>>         <finalName> myClientApp</finalName>
>>     </build>
>>     </project>
>> 
>> 
>> 
>> Did I miss something ?
>> 
>> Thanks for your help.
>> 
>> 
>> regards, 
>> Benjamin
>> -----------------------------------------------------
>> Benjamin Jailly
>> 
>> Laboratoire Télécom Claude Chappe
>> Équipe de recherche SATIN
>> Bureau I012
>> 
>> TELECOM Saint-Etienne
>> 25 rue du Dr Rémy Annino
>> 42 000 Saint-Étienne
>> 
>> [email protected]
>> 
> <Guillaume_Sauthier.vcf>

-----------------------------------------------------
Benjamin Jailly

Laboratoire Télécom Claude Chappe
Équipe de recherche SATIN
Bureau I012

TELECOM Saint-Etienne
25 rue du Dr Rémy Annino
42 000 Saint-Étienne

[email protected]