[jboss-user] [jBPM] - WorkItemHandler Deployment Problem

Reza Ghalavand do-not-reply at jboss.com
Mon Sep 24 08:36:05 EDT 2012

Reza Ghalavand [https://community.jboss.org/people/allgreenphosphor] created the discussion

"WorkItemHandler Deployment Problem"

To view the discussion, visit: https://community.jboss.org/message/761106#761106

Hi everyone,

I'm new to JBoss. I've been using demo installer for a few days testing it, and right now I'm trying to register a workitemhandler of my own.
so far I've edited CustomWorkItemHandlers.conf in notepad just as everyone says and made a WorkItemHandler class.

here's my CustomWorkItemHandlers.conf:

  "Log": new org.jbpm.process.instance.impl.demo.SystemOutWorkItemHandler(),
*  "MyLog": new com.myTask.WorkItemHandler(),*

and here's the WorkItemHandler class itself in java:

package com.myTask;

import java.io.FileWriter;
import java.io.IOException;
import org.drools.runtime.process.WorkItem;
import org.drools.runtime.process.WorkItemHandler;
import org.drools.runtime.process.WorkItemManager;

public class MyTaskHandler implements WorkItemHandler {

          public void abortWorkItem(WorkItem arg0, WorkItemManager arg1) {

          public void executeWorkItem(WorkItem arg0, WorkItemManager arg1) {
                    FileWriter out;
                    try {
                              out = new FileWriter("C:\\out.txt");
                              out.write("Greetings from handler!");
                    } catch (IOException e) {

the problem is I have no prior experience with JBoss AS (nor with any other Java AS) and I have difficulty figuring out where to actually put my jar file so it gets deployed correctly. it's hard to tell because demo installer uses temproary folders which get deleted each time I stop/restart server. I'm kind of confused.

thanks in advance
PS: It's jBPM 5.3.0

Reply to this message by going to Community

Start a new discussion in jBPM at Community

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20120924/42f5b808/attachment-0001.html 

More information about the jboss-user mailing list