Java Service Deployment failed
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-15-2010 05:21 AM
I am trying to deploy the sample Java Service Task (ToUpperCase).
my deployment failed with below error .
[deploy-bar] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
[deploy-bar] at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
[deploy-bar] at org.apache.tools.ant.Main.runBuild(Main.java:758)
[deploy-bar] at org.apache.tools.ant.Main.startAnt(Main.java:217)
[deploy-bar] at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
[deploy-bar] at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
[deploy-bar] Caused by: org.activiti.engine.ActivitiException: Couldn't load cla
ss org.activiti.examples.bpmn.servicetask.ToUppercase[deploy-bar] at org.activiti.engine.impl.util.ReflectUtil.loadClass(ReflectUtil.java:64)
[deploy-bar] at org.activiti.engine.impl.util.ReflectUtil.instantiate(ReflectUtil.java:111)
[deploy-bar] … 33 more
BUILD FAILED
D:\activiti\activiti-5.0.rc1\setup\build.xml:404: couldn't deploy bar D:\activiti\activiti-5.0.rc1\setup\build\ToUppercase.bar: couldn't instantiate class org.activiti.examples.bpmn.servicetask.ToUppercase
I am using ant to deploy.
my ant script as below:
<target name="deploy.touppercase" depends="internal.classpath.libs">
<zip destfile="${activiti.home}/setup/build/ToUppercase.bar">
<fileset dir="${activiti.home}/apps/eclipse-workspace/servicetaskdelegation">
<include name="org/activiti/examples/bpmn/servicetask/ToUppercase.class"/>
<include name="org/activiti/examples/bpmn/servicetask/ToUppercase.java"/>
<include name="org/activiti/examples/bpmn/servicetask/ToUppercase.jar"/>
<include name="org/activiti/examples/bpmn/servicetask/JavaServiceTaskTest.testJavaServiceDelegation.bpmn20.xml"/>
</fileset>
</zip>
<taskdef name="deploy-bar" classname="org.activiti.engine.impl.ant.DeployBarTask">
<classpath>
<pathelement path="files/demo"/>
<fileset dir="build">
<include name="activiti-cfg.jar"/>
</fileset>
<fileset dir="${activiti.home}/examples/activiti-engine-examples/libs-runtime" />
<fileset dir="${activiti.home}/examples/activiti-engine-examples/libs-test" />
</classpath>
</taskdef>
<deploy-bar file="${activiti.home}/setup/build/ToUppercase.bar" />
</target>
also i tried to put the jar file in the tomcat/lib,
still the same error ..
is there any mistake in my deployment ??
my deployment failed with below error .
[deploy-bar] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
[deploy-bar] at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
[deploy-bar] at org.apache.tools.ant.Main.runBuild(Main.java:758)
[deploy-bar] at org.apache.tools.ant.Main.startAnt(Main.java:217)
[deploy-bar] at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
[deploy-bar] at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
[deploy-bar] Caused by: org.activiti.engine.ActivitiException: Couldn't load cla
ss org.activiti.examples.bpmn.servicetask.ToUppercase[deploy-bar] at org.activiti.engine.impl.util.ReflectUtil.loadClass(ReflectUtil.java:64)
[deploy-bar] at org.activiti.engine.impl.util.ReflectUtil.instantiate(ReflectUtil.java:111)
[deploy-bar] … 33 more
BUILD FAILED
D:\activiti\activiti-5.0.rc1\setup\build.xml:404: couldn't deploy bar D:\activiti\activiti-5.0.rc1\setup\build\ToUppercase.bar: couldn't instantiate class org.activiti.examples.bpmn.servicetask.ToUppercase
I am using ant to deploy.
my ant script as below:
<target name="deploy.touppercase" depends="internal.classpath.libs">
<zip destfile="${activiti.home}/setup/build/ToUppercase.bar">
<fileset dir="${activiti.home}/apps/eclipse-workspace/servicetaskdelegation">
<include name="org/activiti/examples/bpmn/servicetask/ToUppercase.class"/>
<include name="org/activiti/examples/bpmn/servicetask/ToUppercase.java"/>
<include name="org/activiti/examples/bpmn/servicetask/ToUppercase.jar"/>
<include name="org/activiti/examples/bpmn/servicetask/JavaServiceTaskTest.testJavaServiceDelegation.bpmn20.xml"/>
</fileset>
</zip>
<taskdef name="deploy-bar" classname="org.activiti.engine.impl.ant.DeployBarTask">
<classpath>
<pathelement path="files/demo"/>
<fileset dir="build">
<include name="activiti-cfg.jar"/>
</fileset>
<fileset dir="${activiti.home}/examples/activiti-engine-examples/libs-runtime" />
<fileset dir="${activiti.home}/examples/activiti-engine-examples/libs-test" />
</classpath>
</taskdef>
<deploy-bar file="${activiti.home}/setup/build/ToUppercase.bar" />
</target>
also i tried to put the jar file in the tomcat/lib,
still the same error ..
is there any mistake in my deployment ??
Labels:
- Labels:
-
Archive
2 REPLIES 2
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-15-2010 02:58 PM
When you deploy, the class needs to be on the classpath.
So, it must be added to your classptah of your ant task.
However, when I now think about it, this is not really easy to use - since you would also need to have it on the classpath on your war or server environment.
So, it must be added to your classptah of your ant task.
However, when I now think about it, this is not really easy to use - since you would also need to have it on the classpath on your war or server environment.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2010 03:32 AM
thanks it works
I added the jar file in to the path
<fileset dir="${activiti.home}/examples/activiti-engine-examples/libs-test" />
I added the jar file in to the path
<fileset dir="${activiti.home}/examples/activiti-engine-examples/libs-test" />
