This snippet from my build.xml works for me. Two things:
1) It renders some warnings about the ejbc classpath having the home
interface class in the path. From what I can tell, these can be ignored. I
haven't figured out exactly how to get rid of them, but they don't seem to
harm anything.
2) From some reason, I too have a problem with the task finding the DTDs for
the deployment descriptors. I don't believe this to be an Ant problem,
instead it's something with weblogic.ejbc. So, what I did is create a local
copy of the DTD and added a <dtd> nested element in the target (which you'll
see in the code).
<target name="ejbs"
depends="classes"
description="generates ejbs">
<echo message="--(DT)--> Generating ejbs"/>^M
<copy todir="${opel.build}">
<fileset dir="${opel.src}"
includes="**/ejb-jar.xml,**/weblogic-ejb-jar.xml"/>
</copy>
<copy todir="${opel.build}">
<fileset dir="${opel.src}">
<patternset id="opel.rdbms.deployment.descriptors">
<include name="**/*rdbms*"/>
</patternset>
</fileset>
</copy>
<ejbjar srcdir="${opel.build}"
descriptordir="${opel.build}"
classpath="${opel.classpath}"
naming="ejb-name"
manifest="${opel.home}/MANIFEST.MF"
flatdestdir="true">
<weblogic destdir="${opel.release}"
keepgeneric="false"
rebuild="false"
wlclasspath="${wls.classpath};${opel.build}"
noEJBC="${opel.noejbc}"
newCMP="false">
</weblogic>
<dtd publicId="-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans
2.0//
EN"
location="${opel.home}/ejb-jar_2_0.dtd"/>
<include name="**/ejb-jar.xml"/>
<exclude name="**/*weblogic*.xml"/>
</ejbjar>
</target>
It may not be the most elegant set up and YMMV, but it works for me :).
Cheers!
Eddie
-----Original Message-----
From: Ajay Chitre [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 01, 2002 9:31 AM
To: [EMAIL PROTECTED]
Subject: EJBJar under Weblogic 6.1...
Hello,
I am running into problems with the 'ejbjar' task under Weblogic 6.1. This
task used to work very well under Weblogic 5.1, but when I run it under
WL 6.1 I get two Warnings. One related to DTDs & the other related to
classpath.
Here are my questions;
1) Can I use ejbjar task for building ejbs under 6.1? All the examples
that come with WL 6.1 call weblogic.ejbc directly as follows;
<java classname="weblogic.ejbc" fork="yes">
Is this how I should be doing it? Is ejbjar task going away?
2) Previously I used the following lines related to DTDs;
<dtd publicId="-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans
1.1//EN"
location="${wl.home}/classes/weblogic/ejb/deployment/xml/ejb-jar.dtd"/>
<dtd publicId="-//BEA Systems, Inc.//DTD WebLogic 5.1.0 EJB//EN"
location="${wl.home}/classes/weblogic/ejb/deployment/xml/weblogic-ejb-jar.dt
d"/>
I can't find 'ejb-jar.dtd' & 'weblogic-ejb-jar.dtd' in my /bea folder.
Where can I find them?
Thanks for your time.
Ajay Chitre
Diligent Team, Inc.
(Where Diligent People Work as a Team)
http://www.DiligentTeam.com
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>