Bug 1035259 - Could not find a work item handler for REST
Summary: Could not find a work item handler for REST
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss BPMS Platform 6
Classification: Retired
Component: Business Central
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ER6
: 6.0.0
Assignee: Maciej Swiderski
QA Contact: Ivo Bek
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-11-27 11:49 UTC by Ivo Bek
Modified: 2014-08-06 20:12 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-08-06 20:12:28 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
the process definition with a rest task (5.58 KB, application/xml)
2013-11-27 11:49 UTC, Ivo Bek
no flags Details

Description Ivo Bek 2013-11-27 11:49:00 UTC
Created attachment 829653 [details]
the process definition with a rest task

Description of problem:

I have a process with a REST task, for which the Rest work item handler is registered in business-central.war/.../META-INF/CustomWorkItemHandlers.conf :

"Rest": new org.jbpm.process.workitem.rest.RESTWorkItemHandler()

But when I want to start this process, I receive WorkItemHandlerNotFoundException: Could not find work item handler for Rest

This is the element for the webservice task <bpmn2:task id="_4" tns:taskName="Rest" name="Any Rest Operation"> but I'll attach the whole process definition.

I also noticed that the rest service is not available in BPMN web designer, so it might mean something.

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. Start a process containing a rest task
2. See WorkItemHandlerNotFoundException in the server log

Actual results:


Expected results:


Additional info:

Comment 2 Ivo Bek 2013-11-27 11:50:35 UTC
This issue is very similar to BZ 1035256 where a web service work item handler cannot be found.

Comment 3 Maciej Swiderski 2013-11-27 18:55:50 UTC
problem was caused be not found CustomWorkItemHandlers.conf file due to not using correct class loader. Since the BPMS uses EAP modules it was not using the web app class loader to look up for resources and thus these work item handlers were not registered. fixed by ensuring that the context class loader is used to look up resources as well which in EAP is the web application class loader.

droolsjbpm-knowledge
master:
https://github.com/droolsjbpm/droolsjbpm-knowledge/commit/3aa65069b5b2169603341d5c3cf95a603de4ad1f

6.0.x:
https://github.com/droolsjbpm/droolsjbpm-knowledge/commit/6a97078da7ebe799f44baebefd762287fc1c1c1d

Comment 4 Maciej Swiderski 2013-11-27 18:57:20 UTC
*** Bug 1035256 has been marked as a duplicate of this bug. ***

Comment 5 Kris Verlaenen 2013-12-09 15:18:01 UTC
Workaround: go to bpms-6.0.0.ER5/jboss-eap-6.1/standalone/deployments/business-central.war/WEB-INF/classes/META-INF and move the following two files to your home directory:
drools.session.conf
CustomWorkItemHandlers.conf

Comment 6 Ivo Bek 2013-12-09 15:39:29 UTC
Kris, thank you... I didn't know about this feature :) I can confirm that it works with this workaround.

Comment 7 Ivo Bek 2014-01-06 13:22:01 UTC
Verified in BPMS 6.0.0.ER7


Note You need to log in before you can comment on or make changes to this bug.