I made a process.
<process id="TestCMD" name="TestCMD">
<documentation>Place documentation for the 'TestCMD' process here.</documentation>
<startEvent id="startevent1" name="Start" activiti:formKey="TestCMD"></startEvent>
<serviceTask id="servicetask1" name="Service Task" activiti:class="activiti.TestAtom"></serviceTask>
<endEvent id="endevent1" name="End"></endEvent>
<sequenceFlow id="flow2" name="" sourceRef="startevent1" targetRef="servicetask1"></sequenceFlow>
<sequenceFlow id="flow3" name="" sourceRef="servicetask1" targetRef="endevent1"></sequenceFlow>
</process>
Service Task: service class is TestAtom.
TestAtom is
public class TestAtom implements JavaDelegate {
@Override
public void execute(DelegateExecution arg0) throws Exception {
try {FileWriter fw = new FileWriter("C:/hello.txt");
String s = "temp test!";
fw.write(s, 0, s.length());
fw.flush();} catch (Exception e) {}}}
I export TestAtom into TestAtom.jar, I put the jar into ${activiti.home}/apps/apache-tomcat-6.0.29/webapps/activiti-rest/lib/, I upload new ***.XML,but the process does not work. the error info is
Caused by: org.activiti.engine.ActivitiClassLoadingException: Class not found: activiti.TestAtom
at org.activiti.engine.impl.util.ReflectUtil.loadClass(ReflectUtil.java:81)
at org.activiti.engine.impl.util.ReflectUtil.instantiate(ReflectUtil.java:128)
How can i do it? I have put the jar into ${activiti.home}/apps/apache-tomcat-6.0.29/webapps/activiti-rest/lib/, why the engine can not find the class? what should I do?