State Machine with Assign Flexi task action

  • 14 December 2016
  • 10 replies
  • 23 views

Badge +1

Hi,

 

We have designed the workflow(Nintex workflow 2013) having state machine and assign flexi task action. The assign flexi task action is inside the state machine.

The state machine action has 2 states (Submit and Resubmit) . Submit state has assign flexi task action and it is also starting state.

The assign flexi task action has 3 outcome Reject , Approve and Need More Information.

In Reject and Approve outcome we are updating item and sending notification.

In Need more information outcome , we are changing state machine state (move to Resubmit state). In Resubmit state , we are again changing state(move to Submit state).

 

Now , the workflow is not working at this stage as per expectation i.e. when moving to Submit state from Resubmit state , the task is not creating again.

 

Attached is screen shot of entire workflow.

 

Any suggestion here why it is not working  ?

 

We have also tried adding Pause for action in resubmit state and in this case the task is created again but our requirement is not to add Pause for action in resubmit and expectation is task should be created again when changing state.


10 replies

Badge +16

i would normally have something in the resubmission branch other than a change state - like a wait for item update or something so that you can be sure that something has changed and then change the state again.  otherwise it is effectively just a loop?

Badge +1

Unnecessary adding other action is not preferred . Change state should work here.

Userlevel 5
Badge +14

1. at very first, I somehow miss the point how you designed the workflow.

you assign a task to someone, and give the assignee an option to request for more info.

but then you want to recreate just the same task assigned to just the same assignee(s).

the assignee will hardly acquire that more info while workflow flips between two states.

quite the same with resubmit state - it doesn't have any added value. so if you haven't changed state within 'more info' task outcome at all, state machine would loop back to submit action. so from my point of view resubmit state is as well pointless.

2. you  say new task is not created. but what exactly happens with state machine and/or workflow?

does it switch to submit branch at all? what does it do with flexi task then  - does it skip? or does it hang? or ???

does the workflow fail? what's reason/error?

when state machine switches between states, it takes at least one timer job cycle. does that happen in your case when switching from submit to resubmit and from resubmit to submit states?

finding with pause action is interesting. but without knowing what's in fact going on with workflow is hard to guess how it helps/influences workflow.

3. reg. of use pause  action within resubmit branch: you assign a task to a human(s). so you can not be sure when he responds. in ideal case it will be in a range of dozen of minutes.

one additional pause in extent of one timer job cycle doesn't matter at all.

4. could you post configuration of flexi task action?

Badge +1

Thanks Marian ...We have managed the things by adding loop. Removed state machine.

State machine was hanged and no task were re created. We don't need pause for action . Pausing for 5 minutes didn't hang the state machine and task were re created after 5-6 minutes(depends on nintex workflow timer job execution).Users may responds within 5 mins.

Thanks

Userlevel 6
Badge +12

‌ - 

You were able to resolve your issue then? If so, please let us know what you did and mark it as answered so that others can quickly find what you did.

Thanks!

Badge +7

Hello Ankur Parmar‌,

 have just gone through the same thing as you with regards to using a State Machine and having an Assign Flexi Task action with in the State Machine.

In my State Machine I had three options Approve, Reject and More Information. But, I really had four states in my State Machine, Pending, Approve, Reject and More Information.

Have a look at my post - Help my State Machine is Looping and another post that I created - Using Switch Action in State Machine.

I got some very good feedback from Nintex community members about a couple of things that I was trying to achieve in my State Machine and using Assign Flexi Tasks.

If you have any further questions that I can help out with please let me know.

Userlevel 5
Badge +14

I'm glad you were able to resolve your issue!

We have managed the things by adding loop. Removed state machine.

that's ok, and that's how does your process seems to look like.

but note, until you have switched off safe looping, you anyway need to wait those 5-6mins (timer job cycle) between two loop iterations.

so, no difference to adding pause action in state machine.

State machine was hanged and no task were re created.

state machine switch and task creation are two different things where it might fail.

try to add some history log entry or mail notification and commit action  before task actions to be sure whether state machine do not switch to respective branch or just task is not created.

but in any case, if this really happens, I think it's worth to report it to ‌ as a bug.

I would say this is not expected behaviour.

Userlevel 7
Badge +17

Great feedback

Userlevel 5
Badge +14

glad  you like it, Andrew 

Hi, 


I am working similar workflow and new to Nintex. Can you please help me where am I going wrong on attached workflow. 

Reply