• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Knute Snortum
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Ganesh Patekar
  • Stephan van Hulst
  • Pete Letkeman
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Ron McLeod
  • Vijitha Kumara

Ant 1.5.2 and ejbjar task  RSS feed

 
Ranch Hand
Posts: 560
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am trying to create one jar "etdummypc-ejb.jar" using <ejbjar> and run <weblogic> task on it. During the ant build process, only two files (DD) are added to the jar file and hence <weblogic> task fails complaining "No Enterprise Java Beans were found the jar file".
Below is my directory structure:
EJBs ->
.\Build\classes\com\icechill\sweep\exptrans\services\dummy\*.class
DD ->
.\Build\classes\com\icechill\sweep\exptrans\services\dummy\META-INF\*.xml
Below is the part of ant build script:

Below is the target where I invoke the above target:

When I execute "ant -buildfile wlbuild.xml doEJB",
<ejbjar> task only include the 2 DD xml files. (ejb-jar.xml and weblogic-ejb-jar.xml). It never includes any of the ejb classes. Please help me with a solution. Thanks a lot.
Note: I do read some properties from a file which is not mentioned in the code above.
ebj-jar.xml
-----------

weblogic-ejb-jar.xml
--------------------

[ March 12, 2003: Message edited by: Sai Prasad ]
 
Sai Prasad
Ranch Hand
Posts: 560
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can anyone post me a sample build.xml using <ejbjar> task? I am trying to get some answers to my earlier question. Moving up the queue...
 
Sai Prasad
Ranch Hand
Posts: 560
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Come on experts...answer my question. Thanks.
 
Ranch Hand
Posts: 165
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
<target name="ejb-jar" depends="compile-ejb" description="Make ejb jar file">
<mkdir dir="${ejb.dir}"/>
<jar
jarfile="${ejb.jar.file}"
>
<fileset dir="${build.classes.dir}">
<include name="**/ejb/**/*"/>
<include name="**/interfaces/**/*"/>
</fileset>
<fileset dir="${build.ejb-meta.dir}"/>
</jar>
</target>

<!-- =================================================================== -->
<!-- Compile business logic (ejb) -->
<!-- =================================================================== -->
<target name="compile-ejb" depends="ejbdoclet" description="Compile business logic (ejb)">
<path id="compile.class.path">
<pathelement path="${lib.dir}/ejb.jar"/>
<pathelement path="${lib.dir}/struts.jar"/>
<pathelement path="${lib.dir}/jdbc2_0-stdext.jar"/>
</path>
<javac
srcdir="${build.gen-src.dir}"
destdir="${build.classes.dir}"
classpathref="compile.class.path"
>
<include name="**/ejb/**/*"/>
<include name="**/interfaces/**/*"/>
</javac>
</target>
 
Matthew X. Brown
Ranch Hand
Posts: 165
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry-I grabbed the wrong text....
<weblogic-ejb-jar>
<description><![CDATA[Generated by XDoclet]]></description>
<weblogic-enterprise-bean>
<ejb-name>Sequence</ejb-name>
<entity-descriptor>
<persistence>
<persistence-type>
<type-identifier>WebLogic_CMP_RDBMS</type-identifier>
<type-version>6.0</type-version>
<type-storage>META-INF/weblogic-cmp-rdbms-jar.xml</type-storage>
</persistence-type>
<persistence-use>
<type-identifier>WebLogic_CMP_RDBMS</type-identifier>
<type-version>6.0</type-version>
</persistence-use>
</persistence>
</entity-descriptor>
<reference-descriptor>
</reference-descriptor>
<local-jndi-name>middlegen.sequencegenerator.ejb.SequenceLocalHome</local-jndi-name>
</weblogic-enterprise-bean>
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!