OW2 Consortium
Search OW2 Mail Archive: 

Advanced Search - Powered by Google


Mail Archive Home | jonas-fr List | August 2004 Index

<--  Date Index  --> <--  Thread Index  -->

RE : [jonas-fr] Pb classpath / jar


Bonjour,

Dans ton client.jar, il te faut les fichiers cd cmp.jar
Tes ejbs clients ne peuvent pas appeler les ejbs cmp si ils n'ont pas
les sources non ?

Aussi, pour info, si j'ai bien compris, tu vas passer par les interfaces
distantes 
pour appeler tes ejbs cmp depuis tes ejbs de session ?

Il faut savoir que passer par les interfaces locales augmenterait
grandement les performances...

A+
Stéphane TRAUMAT

-----Message d'origine-----
De : julien.rombouts@xxxxxxxxxxx [mailto:julien.rombouts@xxxxxxxxxxx] 
Envoyé : vendredi 13 août 2004 10:15
À : jonas-fr@xxxxxxxxxxxxx
Objet : [jonas-fr] Pb classpath / jar


Bonjour,



Dans un jar appellé cmp.jar j'ai tous mes CMP (logique)

Ce jar est bien contruit avec le genic et se trouve dans
%JONAS_BASE%/ejbjars/



Maintenant, je veux constuire un jar clients.jar qui va utiliser des cmp
de cmp.jar... la creation du jar ne pose pas de pb mais lors du genic,
j'obtient cela :



jonas-jar:

   [delete] Deleting directory C:\JOnAS-4.1.2\ejbjars\clients_jonas

    [unjar] Expanding: C:\JOnAS-4.1.2\ejbjars\clients.jar into
C:\JOnAS-4.1.2\ej

bjars\clients_jonas

   [delete] Deleting: C:\JOnAS-4.1.2\ejbjars\clients.jar

[jonasEjbJjar] building clients.jar with 13 files

    [genic] Error during execution of
org.objectweb.jonas_ejb.genic.GenIC : cmp/

ClientValue

    [genic] java.lang.NoClassDefFoundError: cmp/ClientValue



Que dois je faire pour qu'il prenne en compte mon package cmp.jar ?

Si dans mon build.xml j'importe les sources des cmp, ca marche... mais
je ne vais pas les remettres, ca n'a pas de sens!!!



Comment faire?



Merci a vous

Julien



Ps : j'utilise lomboz 3.01 et JOnAS 4.1.2 et ant 1.6.2



ps : la tache que j'execute est : ant compile 



mon build.xml



<?xml version="1.0"?>



<!-- Copyright (c) 2002,2003,2004 by eteration a.s.

      www.eteration.com 

      All rights reserved. -->

<!-- DO NOT MODIFY THIS FILE CHANGE THE SERVER FILE INSTEAD -->







<project name="ejbModuleBuilder" default="ejbdoclet" basedir=".">



   <!-- Init -->

   <target name="init">

      <property file="build.properties"/>

   </target>



   <!-- Run EJBDoclet -->

   <target name="ejbdoclet" depends="init">

          <ant antfile="xdoclet.xml" dir="." target="ejbdoclet">

            <property name="ejb" value="${ejb}"/>

            <property name="deploy.dir" value="${deploy.dir}"/>

        <property name="ejbsrc.dir" value="${ejbsrc.dir}" />

        <property name="bin.dir" value="${bin.dir}" />    

        <property name="project.dir" value="${project.dir}" />    

        <property name="project.path" value="${project.path}" />    

          </ant>

   </target>





   <!-- Create EJB-JAR file -->

   <target name="ejb-jar" depends="init">

          <delete file="${ejb}.jar" failonerror="false" />

      <jar jarfile="${ejb}.jar">         

        <fileset dir="${project.dir}/${bin.dir}">   

           <include name="clients/*.*"/>

        </fileset>

        <fileset dir="..">   

           <include name="META-INF/**/*.*"/>

           <exclude name="META-INF/beans.xml"/>

           <exclude name="META-INF/build.xml"/>

           <exclude name="META-INF/deploy.xml"/>

           <exclude name="META-INF/undeploy.xml"/>

           <exclude name="META-INF/build.properties"/>

           <exclude name="META-INF/ejbs.xml"/>

           <exclude name="META-INF/xdoclet.xml"/>

           <exclude name="META-INF/servers.xml"/>

           <exclude name="META-INF/targets.xml"/>

        </fileset>

      </jar>

   </target>





   <!-- Deploy module to server ... -->

   <target name="deploy" depends="ejb-jar">

      <copy todir="${deploy.dir}">

         <fileset dir="." includes="${ejb}.jar"/>

      </copy>

      <delete file="${ejb}.jar" failonerror="false" />

   </target>



   <!-- Do server specific registration tasks - deploy.xml is specified
in 

        the .server files and generated automatically. ... -->

  <target name="deployTool">

          <ant antfile="./deploy.xml" dir="." target="deploy"
inheritall="true">

          </ant>

  </target> 

    

          <target name="compile" depends="deploy">

                  <ant antfile="./deploy2.xml" dir="." target="deploy2"
inheritall="true">

                  </ant>

          </target> 

    

   <!-- Remove module from the server ... -->

   <target name="undeploy" depends="init">

    <!-- Sometimes you can undeploy with deleting the module file but it
is best dealt on an appserver basis

         at undeployTool target -->

   </target>

   

   <!-- Do server specific remove tasks - undeploy.xml is specified in 

        the .server files and generated automatically. ... -->

   <target name="undeployTool" depends="init">

          <ant antfile="./undeploy.xml" dir="." target="undeploy"
inheritall="true">

          </ant>

   </target> 

  

</project>





mon deploy2.xml





                        

                        <!-- Copyright (c) 2002 by ObjectLearn. All
Rights Reserved. -->

                        <!-- DO NOT MODIFY THIS FILE CHANGE THE SERVER
FILE INSTEAD -->

                                <project name="deployextension"
default="deploy"  basedir=".">

                                 <!-- ejbjar task  -->

                                 <taskdef name="jonasEjbJjar"

        
classname="org.objectweb.jonas.ant.EjbJar"

        
classpath="C:/JOnAS-4.1.2/lib/common/ow_jonas_ant.jar" />

                                    

                                  <path id="base.classpath">

                                    <!-- CLASSPATH is added for runtest
target -->

                                    <fileset dir="C:/JOnAS-4.1.2/lib">

                                      <include name="**/*.jar"/>

                                      <include name="**/**/*.jar"/>

                                      <include name="**/**/**/*.jar"/>

                                      <exclude
name="**/ow_jonas_bootstrap.jar"/>

                                    </fileset>

                                  </path>                               

                              <path id="toolpath">

                                        <!-- append the external
classpath lastly -->

                                        <pathelement
path="${java.class.path}" />

                                        <!-- append the path sent
through eclipse to classpath -->

                                        <pathelement
path="${adminToolPath}" />  

                                  </path>



                                  <target name="jonas-jar"
unless="bypass-server-jar" >

                                        <delete
dir="${deploy.dir}/${ejb}_jonas" failonerror="false" />

                                     

                                        <unjar
src="${deploy.dir}/${ejb}.jar" dest="${deploy.dir}/${ejb}_jonas"/> 

                                        <delete
file="${deploy.dir}/${ejb}.jar" failonerror="false"  />



                                    <jonasEjbJjar basejarname="${ejb}"

        
srcdir="${deploy.dir}/${ejb}_jonas"

        
descriptordir="${deploy.dir}/${ejb}_jonas/META-INF" 

                                            dependency="full" >

                                      <include name="**/ejb-jar.xml"/>

                                      <dtd publicId="-//Sun
Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"

        
location="C:/JOnAS-4.1.2/xml/ejb-jar_2_0.dtd" />

                                      <support
dir="${deploy.dir}/${ejb}_jonas">

                                                <include name="**/*.*"/>

                                                <exclude
name="**/MANIFEST.MF"/>

                                                <exclude
name="**/ejb-jar.xml"/>

                                                <exclude
name="**/jonas-ejb-jar.xml"/>

                                      </support>

                                      <jonas destdir="${deploy.dir}"

        
classpath="${base.classpath}:${deploy.dir}/${ejb}_jonas" 

                                             jonasroot="C:/JOnAS-4.1.2" 

                                             mappernames="rdb.mysql"

                                         protocols="jrmp"

                                             keepgenerated="true" />

                                    </jonasEjbJjar>

                                        <delete
dir="${deploy.dir}/${ejb}_jonas" failonerror="false" /> 

                                 </target>

                                 <target name="jonas-deploy"
unless="bypass-server-deploy" >

                                          <java 

        
classname="org.objectweb.jonas.server.Bootstrap" 

                                                fork="true" 

                                                classpathref="toolpath"
>

                                              <arg
value="org.objectweb.jonas.adm.JonasAdmin" />  

                                              <arg value="-a" />

                                              <arg
value="${deploy.dir}/${ejb}.jar" />

                                              <jvmarg
value="-Dinstall.root=C:/JOnAS-4.1.2" />

                                              <jvmarg
value="-Djonas.base=C:/JOnAS-4.1.2" />

                                              <jvmarg
value="-Djava.security.policy=C:/JOnAS-4.1.2/conf/java.policy" />

                                              <jvmarg
value="-Djonas.classpath=" />

                                              <jvmarg
value="-Djonas.default.classloader=true" />

                                              <jvmarg
value="-Djavax.rmi.CORBA.PortableRemoteObjectClass=org.objectweb.carol.r
mi.multi.MultiPRODelegate" />

                                              <jvmarg
value="-Djava.naming.factory.initial=org.objectweb.carol.jndi.spi.MultiO
rbInitialContextFactory" />

                                              <jvmarg
value="-Djava.security.auth.login.config=C:/JOnAS-4.1.2/conf/jaas.config
" />

                                              <jvmarg
value="-Djava.rmi.server.RMIClassLoaderSpi=org.objectweb.jonas.server.Re
moteClassLoaderSpi" />                                

                                           </java>

                                  </target>

                                  <target name="deploy"
depends="jonas-jar,jonas-deploy" >

                                  </target>

        
<target name="deploy2" depends="jonas-jar" >

                                  </target>

                                </project>

                                

                


---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.737 / Virus Database: 491 - Release Date: 11/08/2004
 
  

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.737 / Virus Database: 491 - Release Date: 11/08/2004
 




<--  Date Index  --> <--  Thread Index  -->

Reply via email to:

Powered by MHonArc.

Copyright © 2006-2007, OW2 Consortium | contact | webmaster.