-
1. Re: Calling two different work item handler from different nodes
heathcliff Oct 6, 2011 6:00 AM (in response to snyperboss)The idea of handlers and work items is that you have one type of work item that it presents some idea/functionality like "Notification" so i has one handler with different parameters passed to it.
You could also make some generic notifivation handler with attribute specifing behavior and than from that handler delegate execution to apropriate class. this is if you wont different behavion for the same work item.
-
2. Re: Calling two different work item handler from different nodes
tsurdilovic Oct 6, 2011 12:56 PM (in response to snyperboss)1 of 1 people found this helpfulHi, as Adam said, the mapping of a service task name to the handler implementation is pre-configured and cannot be changed at runtime afaik. You would either create two different handlers or have one that is smart enough to do whats needed depending on that parameters you pass in.
Hope this helps.
-
3. Re: Calling two different work item handler from different nodes
swiderski.maciej Oct 6, 2011 1:42 PM (in response to snyperboss)1 of 1 people found this helpfulAnother approach could be that (of course depending on your process) you create a session and register notification handler A then start the process that executes the notification node then goes to a wait state lets say receive task, so you could dispose the session.
After a while you load the session and register the second (B) notification handler and signal the process to continue its operation.
That should work since you register the work item handlers on the session upon its creation (either a new one or after loading it from data store).
This is the flexibility that jBPM/Drools gives you but final solution is up to you. Just my two cents