Parallel Multi-Instance Loop

603 views
Skip to first unread message

javiermm...@gmail.com

unread,
Mar 26, 2015, 7:21:12 AM3/26/15
to suppor...@runmyprocess.com
Hi,

I'm trying to use a Parallel Multi-Instance Loop, but I don't understand how it works.
I only want it is more familiar to me, but after reading the documentation, I still have not understood how it works, and the cases in which I can use it.

I understand Multi-instances sequence and parallel make the same operation in different times, the first one makes the task 1 by 1, and the second one, all at the same time. But is the result the same (in equivalent conditions)?

And I have more questions: Where is RMP taking the array variable from?
My attempts are showing me an error saying my variable is not a valid array. What is the format I need to use? Where should I add the array?

Thanks in advance,

Regards.

Sweta Suman

unread,
Mar 26, 2015, 8:04:08 AM3/26/15
to suppor...@runmyprocess.com
Hi,

1) Result may vary depending upon scenario you are using. E.g-

   a) When you want to assign a single task to multiple users and they can perform action independently.(Multi instance parallel loop)

   b) If you have approval workflow which consist of set of manual task in that scenario it should be sequential.

2) Are you passing array in loop activity ? 
   Array created is not in proper format. correct format is -{"radio":["saas"],"name":["Test"],"address":["XYZ"]}


Hope this helps you.

Thanks,
Sweta

Javier Martín

unread,
Mar 27, 2015, 3:47:48 AM3/27/15
to suppor...@runmyprocess.com
Hi,


2) Are you passing array in loop activity ?
Where should I do? Input variable? array filed in Loop Tab of the activity configuration? I've tried this, but the error persists...


correct format is -{"radio":["saas"],"name":["Test"],"address":["XYZ"]}
That's not the format I had use.
In fact, I was using something easier like [1,2,3,4,5]. And in a desperate try, I added the variable to the input of the process. And the result was that the process finish correctly but the process didn't do anything.


1) Result may vary depending upon scenario you are using. E.g-
   a) When you want to assign a single task to multiple users and they can perform action independently.(Multi instance parallel loop)
   b) If you have approval workflow which consist of set of manual task in that scenario it should be sequential.
I guess, I don't understand the operation mode of the Multi-instance parallel Loop. If I add a input variable to the loop activity like list = [1,2,3,4,5], and I want, for example that all array positions ares multiplied by 2. Can I do it in a single step with this kind of Loop?
Is the parallel word referring to the capability for making concurrent operations? or It's most likely to the capability for executing the activity by differents users at the same time?
Can you explain me how does the Multi-instance parallel Loop works, with an example please?

I would like to understand well the RMP features, so I would thank you more information about that.

Regards.

--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to a topic in the Google Groups "Fujitsu RunMyProcess Developer Community" group.
To unsubscribe from this topic, visit https://groups.google.com/a/runmyprocess.com/d/topic/supportforum/K8AzNz-OHrM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.
To view this discussion on the web visit https://groups.google.com/a/runmyprocess.com/d/msgid/supportforum/CAEibfQ-5gzOmKpBFJqMBmaV43dhps6b7e2sya28K-CaJWj-iAw%40mail.gmail.com.

Sweta Suman

unread,
Mar 27, 2015, 7:21:57 AM3/27/15
to suppor...@runmyprocess.com
Hi,

Yes it can be done in single activity. Write below free marker script in input variable of activity (type is none).

<#assign new_list=[]>
<#list [1, 2, 3, 4] as x> //defining list of values
<#assign new_list = new_list +[2 * x]> //multiplying by 2 and store in new_list
</#list>  
${new_list} //print 


Yes, multi-instance parallel loop refer to the capability for executing the activity by different users at the same time.

Let's take an scenario of Reporting System in which all executive need to provide input and update to Higher officer.

1)There is a Parent process which can be triggered by either Timer/Mail/WI.

  a) First activity we store list of executive/users in array.
  b) Second activity type loop iterating as per "User" array. Calling sub-process and allocating task simultaneously to multiple executive.
  c) Third activity is of type "Email" sending notification to Higher officer that update has been done.(Once sub-process will complete this activity will execute)
  
2) Sub process -

   a) Manual activity which will allocate task to multiple user(notified through email).
   b) Action will be taken by all executive independently.
   c) As executive will enter the information/ comments and submit the form. Information will be sent to parent process. Similarly, for executive 2..and so on.
   d) Once all executive fill it sub-process will complete.

Please refer attachment for workflow of above scenario.

Hope this helps you.

Thanks,
Sweta
 
You received this message because you are subscribed to the Google Groups "Fujitsu RunMyProcess Developer Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.

To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.
parent_process.png
loop.png
subprocess.png

Javier Martín

unread,
Mar 30, 2015, 3:41:38 AM3/30/15
to suppor...@runmyprocess.com
Hi Sweta,

Thanks for the example, but I'm trying to copy it, and I think there is something going wrong. You'll see:

I have two users more, who have the role employee. My user has the role Designer.
If I've understood well, the values of the array that is being used by the Loop activity (Users) identify the users that have to receive the task, right? So If i fill the array with ["employee_1", "employee_2"], these users will receive a request for this task, aren't they?
Well, my problem is that these requests, are arriving to my own user (designer), and the other ones("Susana" y "Lucia" in the image) cannot see the task.

I attach some screenshoots for a better explanation.
What's going wrong?

Regards.


Calling sub-process (Input variables).png
Calling sub-process (Loop).png
Multi-instance parallel Loop.png
Sub-proceso.png
Users output variables.png
WI.png

Sweta Suman

unread,
Mar 30, 2015, 7:59:25 AM3/30/15
to suppor...@runmyprocess.com
Hi,

If you are Launching application in "Test" mode only initiator will receive the mail. However in Acceptance & live mode email will go to the specific person.

Since you are selecting users from WI list widget their respective email-id will be stored in list array and sub process will iterate as per that.

In process loop activity pass ${list} instead of Users where list is value variable of list widget.

In input variable of sub process activity take a another variable allocate value as ${list[P_index]}.

Write ${allocate} in "Assign To" field of manual activity in sub process so that users selected from list will be getting task mail.

Also, you can select multiple users from list check "Multi-selection" option in list widget of WI. 

Hope this helps you.

Thanks,
Sweta

Javier Martín

unread,
Mar 31, 2015, 2:52:39 AM3/31/15
to suppor...@runmyprocess.com
Hi again,

I've followed all your instructions, but I'm getting the error below:

Task "Assigning the task" (id: 1[0] - status: ABORTED): Error while processing {allocate}
Expression allocate is undefined on line 1, column 3 in Assigning the task.

What I do, In summary:
1.- Select the user from the list.
2.- Put this list on loop activity
3.- Execute the Multi-Instance Parallel Loop with the subprocess
   3.a.- An empty window is showed with only a button to cotinue.   <-----Here is the error.
4.- Send mail.

It seems like sub-process doesn't recognize the allocate variable, but I thought that all variables were global variables. Am I wrong? Why is my activity aborting the process?

Thanks in advance, and sorry for the invenience,
Regards.

Sweta Suman

unread,
Mar 31, 2015, 3:27:37 AM3/31/15
to suppor...@runmyprocess.com
Hi,   

Could you please confirm that you have checked "Send Variable" option in activity calling Sub-process.(refer attachment)

Also, check you are getting allocate variable in computed parameter of parent process.

Thanks,
Sweta


subprocess.png

Javier Martín

unread,
Mar 31, 2015, 3:42:53 AM3/31/15
to suppor...@runmyprocess.com
Hi, 

The send variables option is cheked, and I don't know how to see if I'm getting allocate variable in computed parameters of my parent process, because if I list the process reports, RMP only shows me the sub-process. When the parent process fails I can see the sub-process in the report process, but when the sub-process fails I cannot see the process parent in process report.

How can I check computed parameters of my parent process?

Even if the computed parameters were inherited, the list of this kind of parameters is empty in my subprocess
please, what's happening?

Regards.

Sweta Suman

unread,
Mar 31, 2015, 3:59:32 AM3/31/15
to suppor...@runmyprocess.com
Hi,

Go To Process Report -->Click on Main process-->Parameter-->Computed Parameter.

Please find screenshot for better understanding.

Thanks,
Sweta

p1.png
p2.png
p3.png

Javier Martín

unread,
Mar 31, 2015, 5:33:54 AM3/31/15
to suppor...@runmyprocess.com
Hi,

OK, I can see the computed parameter allocate, and the error has gone. But now, I'm getting the same result as at the beginning. I assign a task to two users, but these users can't see the task in their "my tasks" page. Besides I am the user who is receiving the two tasks insted of the users I've selected in the WI.

Why? How is working the process? I don't understand the flow followed by RMP in the execution.

Regards.

Sweta Suman

unread,
Mar 31, 2015, 8:21:17 AM3/31/15
to suppor...@runmyprocess.com
Hi,

Probably you are executing the process in "Test" mode. In Test mode task will be allocated to initiator and email will only go to initiator. Since you are initiator, task is allocated to you irrespective of users selected in list and will be accessible only by you.

To understand the flow clearly execute the application in Acceptance/Live mode. Create a version of application and put it in Acceptance and test it. Make sure you have added users in "Acceptance users" and provided proper access right ( e.g Employee should have Users access right in your scenario).

For more details refer - 


If problem persist please revert back.

Thanks,
Sweta


javiermm...@gmail.com

unread,
Apr 7, 2015, 6:06:43 AM4/7/15
to suppor...@runmyprocess.com
Thank you, Sweta, Now I can see how is working.
Reply all
Reply to author
Forward
0 new messages