[jboss-user] [jBPM] - Re: How to access a processInstance within a work item
Tobias Wittur
do-not-reply at jboss.com
Mon Sep 19 20:56:27 EDT 2011
Tobias Wittur [http://community.jboss.org/people/tob1as] created the discussion
"Re: How to access a processInstance within a work item"
To view the discussion, visit: http://community.jboss.org/message/627329#627329
--------------------------------------------------------------
Well, it is actually an intermediate message throw event as well as a message throw end event, my xml is at the bottom.
I had a look at the examples and for the *intermediate throw event*, a send task handler was defined:
KnowledgeBase kbase = createKnowledgeBase("*BPMN2-IntermediateThrowEventMessage.bpmn2*");
StatefulKnowledgeSession ksession = createKnowledgeSession(kbase);
ksession.getWorkItemManager().registerWorkItemHandler("Send Task", new SendTaskHandler());
I then looked at the xml for the send task example as well as the intermediate message throw example, neither has any attribute like tns:name="Send Task" and oryx is also not producing one ?
Intermediate message throw event:
> <intermediateThrowEvent id="_2" name="MessageEvent" >
> <dataInput id="_2_Input" />
> <dataInputAssociation>
> <sourceRef>x</sourceRef>
> <targetRef>_2_Input</targetRef>
> </dataInputAssociation>
> <inputSet>
> <dataInputRefs>_2_Input</dataInputRefs>
> </inputSet>
> <messageEventDefinition messageRef="_2_Message"/>
> </intermediateThrowEvent>
> <endEvent id="_3" name="EndEvent" />
>
> //send task
> <sendTask id="_2" name="Hello" messageRef="_2_Message" implementation="Other" >
> <ioSpecification>
> <dataInput id="_2_param" name="Message" />
> <inputSet>
> <dataInputRefs>_2_param</dataInputRefs>
> </inputSet>
> <outputSet/>
> </ioSpecification>
> <dataInputAssociation>
> <sourceRef>s</sourceRef>
> <targetRef>_2_param</targetRef>
> </dataInputAssociation>
> </sendTask>
My process xml:
> <bpmn2:intermediateThrowEvent id="_1246A3A8-08AE-4FEC-AEDB-731A233E28CE" name="Update Twitter Status (throw message)">
> <bpmn2:incoming>_BC5261CD-860C-4979-A045-AE209C41780D</bpmn2:incoming>
> <bpmn2:outgoing>_3E572AF9-62AA-4D13-B0E7-BD1A3B893C80</bpmn2:outgoing>
> <bpmn2:dataInput id="_1246A3A8-08AE-4FEC-AEDB-731A233E28CE_Parameter" name="Parameter"/>
> <bpmn2:dataInputAssociation id="_amcjQ-J1EeC2tu7nt8W9eg">
> <bpmn2:sourceRef>x</bpmn2:sourceRef>
> <bpmn2:targetRef>_1246A3A8-08AE-4FEC-AEDB-731A233E28CE_Parameter</bpmn2:targetRef>
> </bpmn2:dataInputAssociation>
> <bpmn2:inputSet id="_amcjQuJ1EeC2tu7nt8W9eg">
> <bpmn2:dataInputRefs>_1246A3A8-08AE-4FEC-AEDB-731A233E28CE_Parameter</bpmn2:dataInputRefs>
> </bpmn2:inputSet>
> <bpmn2:messageEventDefinition id="_amcjROJ1EeC2tu7nt8W9eg" drools:msgref="twitterProductLink" messageRef="twitterProductLink"/>
> </bpmn2:intermediateThrowEvent>
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/627329#627329]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20110919/c2db06e8/attachment-0001.html
More information about the jboss-user
mailing list