*Background*

We are using Ruote to facilitate marketing campaigns. A common 
step/participant in our campaign is to try to call (via telephone) an 
individual or company. Sometimes we end up having conversations with an 
unexpected individual and at that point we would like to start another 
instance of the same pdef for this new individual. The rub is that we would 
like to skip the preceeding steps and jump down to the "call" particpant 
upon starting the new instance. This might sounds strange but one of our 
underlying philosphies is to have only one target/individual per workflow 
instance.

*Approaches*

We've talked this through and here are the options we have come up with 
along with potential pro's and con's. Is there something we are missing? We 
would love to hear some feedback, even if the feedback is "you're doing it 
wrong"...

*Cursor*

At this time we think the best fit would be to use a cursor and implement a 
"relaunch" participant. The relaunch would start the same pdef with mostly 
the same fields but with a flag of some sort to jump to a new location.

Pros

   - will have a new workflow instance for each "target/conversation"
   - clean fit because construct intended for jumping

Cons

   - requires implementer to understand and include jump command (could add 
   validation)
   

    pdef = Ruote.process_definition do
>       cursor do
>         jump :to => 'call', :if => '${f:jump_to} == true'
>         direct_mail
>         call
>         relaunch :if => '${f:new_conversation} == true'
>         email
>       end
>     end



*Subprocess*

In terms of structuring a workflow so that you could re-run a set of 
participants for many individuals the "subprocess" seems to be a very good 
fit. However, unless we're missing something, this approach would deviate 
from our "one individual per instance" approach.

Pros

* clear deliniation, subprocess is split out and can be repeated

Cons

* no new workflow instance id
* how to stop a specific subprocess

    pdef = Ruote.process_definition do
>       sequence do
>         call
>         subprocess 'fullfillment', :if => "#{f:new_conversation} == true'
>       end
>       define 'fulfillment' do
>         email  :if => '${f:call_result.email_me} == true'
>         direct :if => '${f:call_result.mail_me}  == true'
>       end
>     end



*Separate workflows*

Another option we've discussed would be to define separate pdef's and have 
the first one launch multiple versions of the second if the need arises.

Pros

* most straightforward to code, just need a "launch" participant

Cons

* more for implementers understand and maintain

    call = Ruote.process_definition do
>       cursor do
>         call
>         launch :pdef => 'fulfillment'
>       end
>     end
>
 

    fulfillment = Ruote.process_definition do
>       cursor do
>         email
>         direct
>       end
>     end



-- 
-- 
you received this message because you are subscribed to the "ruote users" group.
to post : send email to [email protected]
to unsubscribe : send email to [email protected]
more options : http://groups.google.com/group/openwferu-users?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"ruote" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to