JBoss Community

Re: Using jBPM as state machine engine - is it a good idea?

created by Maciej Swiderski in jBPM - View the full discussion

I would say you could do this by combining power of jBPM and drools. First of all, I believe that traditional process definition would not fit your needs but ad hoc processes are in my opinion excellent choice here. See some details about ad hoc processes here.

Just one important comment is that you would not rely on process instance state as it's internal information for the engine and cannot be altered based on business data but rather use process variable that can be easily modified by process activities and rules.

 

Generally it would work like this:

- start ad hoc process which will  not make any activity running yet

- signal given activity or execute rules that will decide what activity should be signaled

- at any point a decision needs to be taken a business rule task should be executed that will evaluate what needs to be done:

     - set process variable according to current state of the process

     - signal another activity to continue processing

 

HTH

Reply to this message by going to Community

Start a new discussion in jBPM at Community