hi friends,
When my workflow control comes to auto-method(class Name-WorkflowAutoMethod), it throws Exception as follows and Workflow is paused. This is my auto-method code.
My Auto-Method code,
package workflow.doc.workflow1;
import java.io.PrintWriter;
import com.documentum.bpm.rtutil.WorkflowMethod;
import com.documentum.fc.client.IDfSession;
import com.documentum.fc.client.IDfSysObject;
import com.documentum.fc.client.IDfWorkitem;
import com.documentum.fc.common.IDfProperties;
public class WorkflowAutoMethod extends WorkflowMethod{
public int doTask(IDfWorkitem workitem, IDfProperties arg1, PrintWriter arg2)throws Exception{
workitem.acquire();
System.out.println("With in workitem");
IDfSession session = workitem.getSession();
IDfSysObject obj = (IDfSysObject)session.newObject("dm_folder");
obj.link("/seenu");
obj.setObjectName("testworkflowobj");
obj.save();
System.out.println("=================inside workflowmethod=====================");
workitem.complete();
return 0;
}
}
Exception
java.lang.Exception: Error in loading class workflow.doc.workflow1.WorkflowAutoMethod
at com.documentum.bpm.engine.utils.InvokeWfMethodService.getMethodObj(InvokeWfMethodService.java:145)
at com.documentum.bpm.engine.utils.InvokeWfMethodService.execute(InvokeWfMethodService.java:95)
at com.documentum.bpm.engine.model.activity.WorkflowMethodActivityTaskHandler.executeWorkitem(WorkflowMethodActivityTaskHandler.java:38)
at com.documentum.bpm.engine.runtime.AutomaticWorkitemHandler.executeService(AutomaticWorkitemHandler.java:346)
at com.documentum.bpm.engine.runtime.AutomaticWorkitemHandler.run(AutomaticWorkitemHandler.java:76)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Thread.java:595)
Caused by: java.lang.ClassNotFoundException: workflow.doc.workflow1.WorkflowAutoMethod
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at com.documentum.bpm.engine.utils.InvokeWfMethodService.getMethodObj(InvokeWfMethodService.java:141)
... 7 more
------ please give me suggestion to overcome this Exception,