开发者

Error using Ant to create EJB after upgrading WAS from 6.0 to 7.0

Ant task breaks at the <wsejbdeploy> tag. The exception message is :

[wsejbdeploy] Error executing deployment: java.lang.ClassNotFoundException. 
Error is com.ibm.etools.ejbdeploy.batch.plugin.BatchExtension.
[wsejbdeploy] java.lang.ClassNotFoundException: 
com.ibm.etools.ejbdeploy.batch.plugin.BatchExtension
[wsejbdeploy]   at java.lang.Class.forName(Class.java:136)

In addition to that, ivy.xml reports problems, but when I inspect it, the messages have no sense (screenshot). I suspect the problems could be:

a) Additional files that I have for the build which conflict with the upgraded Ant (in RSA 7.0 i've had Ant 1.6.5 and RSA 8.0 comes with Ant 1.7.1). Additional files are:

required for ant tasks execution

  • ant-contrib/ant-contrib.jar
  • antelope-tasks/AntelopeTasks_3.2.10.jar
  • antform/antform.jar
  • antform/defaultStyle.txt
  • antlr/antlr.jar
  • checkstyle/checkstyle-4.2.jar
  • checkstyle/checkstyle-optional-4.2.jar
  • checkstyle/checkstyle-frames-errors.xsl
  • clover/clover.jar
  • clover/cenquatasks.jar
  • clover/clover.license
  • doccheck/doccheck-modified.jar
  • ivy/ivy-20060723172807.jar
  • jakarta-commons/commons-beanutils.jar
  • resources/checkstyle/checks-source.xml
  • resources/checkstyle/checksTransformation.xsl

b) Changes in t开发者_如何学运维he Ant regarding EJB build which require some settings to be reconfigured.

c) Something else :)

Except the Error, everything else is a stab in the dark so feel free to ask for any additional info.


The problem was in the additional file needed for wsejbdeploy. In the 6.0 version, you copy wsanttasks.jar and wsprofile.jar from the websphere 6.0 installation folder and then reference it like this

<taskdef name="wsejbdeploy" classname="com.ibm.websphere.ant.tasks.WsEjbDeploy"
       classpathref="all-libs"/>

where "all-libs" is a reference to the folder where you copied the jars. In websphere 7.0 there is no wsanttasks.jar and you must reference the runtime file, eg

<taskdef name="wsejbdeploy" classname="com.ibm.websphere.ant.tasks.WsEjbDeploy">
<classpath> 
<pathelement path="C:/IBM/SDP80/runtimes/base_v7/plugins/com.ibm.ws.runtime.jar" /> 
</classpath> 

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜