ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel CAUNE <dani...@in-fusio.com>
Subject HELP: ejbjar tag and EJB exception.
Date Mon, 20 Aug 2001 10:07:21 GMT
Dear all,

I have a little problem with my EJB JAR file creation, using the ejbjar
tag. Some of my EJB have their own exception (derived obviously from
EJBException), but the corresponding exception class is not included
automatically in the EJB JAR file :

 <!-- Create the EJB JAR files -->
 <target name="ejbjar" depends="compile">
   <ejbjar descriptordir="${res}"
	   destdir="${lib}"
           srcdir="${classes}">
     <classpath refid="project.class.path"/>
     <include name="**/*-ejb-jar.xml"/>
     <exclude name="**/*jboss*.xml"/>
     <jboss destdir="${lib}"/>
     <dtd publicId="-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans
1.1//EN"
          location="http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd"/>
     <dtd publicId="-//JBoss//DTD JBOSS//EN"
          location="http://www.jboss.org/j2ee/dtd/jboss.dtd"/>
   </ejbjar>
 </target>

Then the deployment failed, until I provide to JBoss an auxiliary JAR
file containing these exception classes in $JBOSS/lib/ext; but I have to
stop and start JBoss... I feel that to put EJB exception classes in an
auxiliary JAR file, else than the EJB JAR file, is an ugly method, no ?

Do you have a magic tip to ask ejbjar tag for adding EJB exception class
in the EJB JAR file (something generic of course) ? Is there an inner
variable corresponding to the name of the current EJB ejbjar tag
proceeds (so we can add <include name="**/${EJBName}Exception.class"/>)
?

Thanks,


Daniel


Mime
View raw message