Discussion:
[jboss-user] [jBPM] - JBPM 5.4 - send signal event to reusable subprocess
Zeca9 ...
2013-07-12 10:58:28 UTC
Permalink
Zeca9 ... [https://community.jboss.org/people/zeca9] created the discussion

"JBPM 5.4 - send signal event to reusable subprocess"

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

--------------------------------------------------------------
Hi,


I've a main process with a reusable subprocess:
Loading Image... Loading Image...
The reusable subprocess calls a process that has a catch signal event.
Loading Image... Loading Image...
When I launch the Main, I save the process instance id (idMain) in my own DB. But I donÂŽt know anything about the id of the subprocess. That's the problem.


Because I'm using the same session to start all the main process, when I want to signal the event whitin the subprocess for one single instance, i can't just do:
+ksession.signalEvent(event, params);+
because that will trigger all the instances and not just one.

I tried to pass the id of the main (parent process) using the command:
+ksession.signalEvent(event, params, idMain);+
but nothings happens.

I also found that this works
+ksession.signalEvent(event, params, idSubprocess);+
but like I said, I don't have the idSubprocess.


Another way i tried was trying to transform the signalRef attribute unique using a variable (id_main) in the invocation of the subprocess, that will be used in the parameter signalRef=event.#{id_main}. Didn't work beacuse the value wasn't replaced.


Can anyone point me to the right direction?


Is any way to get the idSubProcess knowing only the IdMain?


Or is a way to use a script task before the signal event just to update the signalEvent parameter?


Thanks
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/827714#827714]

Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
Loading...