ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » Workflow Engines - IBM MQ Workflow & Business Process Choreographer » Recursion

Post new topic  Reply to topic
 Recursion « View previous topic :: View next topic » 
Author Message
jk
PostPosted: Mon Feb 17, 2003 3:36 am    Post subject: Recursion Reply with quote

Apprentice

Joined: 09 Jan 2002
Posts: 36

Hi,
i have a main Process PROC A. I have a sub process PROC B. The data structure in PROC B is actually an array. the array is actually a list of people who need to approve a particular item. the array is a name-approval pair.
i have assumed that there could be a maximum number of five people who can approve this process. only at runtime i can find out how many ppl wil be there for approval.

i have done this using the recursion test. i have attached the fdl.

now i want to retain the values of the array (both name and approval values and pass it to PROC A.) In the recursion test e.g. when the loop is called again all the values are replaced.
how can i then retain the values for a larger array?

if one of reject then both PROC A and PROC B have to terminate.

thanx in advance
Back to top
View user's profile Send private message
jmac
PostPosted: Mon Feb 17, 2003 6:04 am    Post subject: Reply with quote

Jedi Knight

Joined: 27 Jun 2001
Posts: 3081
Location: EmeriCon, LLC

The FDL is not attached. You will have to cut and paste it in so we can see it.
_________________
John McDonald
RETIRED
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
jk
PostPosted: Mon Feb 17, 2003 8:43 pm    Post subject: Reply with quote

Apprentice

Joined: 09 Jan 2002
Posts: 36

Hi,
i'm pasting the fdl below.

/*
*
* FDL definitions generated by MQSeries Workflow at 2003-02-18, 10:11:53 AM.
*
*/
CODEPAGE 1252
FM_RELEASE V3R3 2

/*
* STRUCTUREs
*/
STRUCTURE 'a1'
'name': STRING;
'approval': STRING
DESCRIPTION "";
END 'a1'

STRUCTURE 'A_PersonInfo'
'a1': 'a1'(5);
END 'A_PersonInfo'

/*
* PROGRAMs
*/
PROGRAM 'UPES_Program'
STRUCTURES_FROM_ACTIVITY
UNATTENDED
WINNT EXE PATH_AND_FILENAME "fmcnshow.exe"
INHERIT ENVIRONMENT
STYLE INVISIBLE
NO START FOREGROUND
END 'UPES_Program'

/*
* SERVERs
*/
SERVER 'UPES'
RELATED_GROUP 'FMCGRP'
RELATED_SYSTEM 'FMCSYS'
TYPE USER_DEFINED_PROGRAM_EXECUTION_SERVER
MQSYSTEM MQSERIES
MESSAGE_FORMAT XML
PHYSICAL_QUEUE_NAME "UPES"
QUEUE_MANAGER_NAME "FMCQM"
VERSION 3
RELEASE 3
LEVEL 0
END 'UPES'

/*
* PROCESSes
*/
/*
* PROCESS RecursionTest
*/
PROCESS 'RecursionTest' ( 'A_PersonInfo', 'Default Data Structure' )
DO NOT PROMPT_AT_PROCESS_START
WINDOW VIEW_REFERENCE_POINT XPOS -36 YPOS -233
WINDOW SHOW ALL CONNECTORS
WINDOW SHOW TRANSITION_CONDITIONS
SOURCE 1 XPOS -700 YPOS 300
PROGRAM_ACTIVITY 'DummyApp' ( 'A_PersonInfo', 'A_PersonInfo' )
START MANUAL WHEN AT_LEAST_ONE CONNECTOR TRUE
EXIT AUTOMATIC
LAYOUT XPOS -500 YPOS -100
NAME_POSITION XPOS -500 YPOS -175
PRIORITY DEFINED_IN INPUT_CONTAINER
DONE_BY PERSON 'ADMIN'
PROGRAM 'UPES_Program'
PROGRAM_EXECUTION_UNIT 'UPES.FMCSYS.FMCGRP'
SYNCHRONIZATION CHAINED
END 'DummyApp'
PROCESS_ACTIVITY 'Process' ( 'A_PersonInfo', 'A_PersonInfo' )
START AUTOMATIC WHEN AT_LEAST_ONE CONNECTOR TRUE
EXIT AUTOMATIC
LAYOUT XPOS 300 YPOS -900
NAME_POSITION XPOS 300 YPOS -975
PRIORITY DEFINED_IN INPUT_CONTAINER
PROCESS 'RecursionTest'
END 'Process'
PROGRAM_ACTIVITY 'Program' ( 'a1', 'a1' )
START AUTOMATIC WHEN AT_LEAST_ONE CONNECTOR TRUE
EXIT AUTOMATIC
LAYOUT XPOS 300 YPOS -100
NAME_POSITION XPOS 300 YPOS -175
PRIORITY DEFINED_IN INPUT_CONTAINER
PROGRAM 'UPES_Program'
PROGRAM_EXECUTION_UNIT 'UPES.FMCSYS.FMCGRP'
SYNCHRONIZATION CHAINED
END 'Program'
PROGRAM_ACTIVITY 'Program1' ( 'a1', 'a1' )
START AUTOMATIC WHEN AT_LEAST_ONE CONNECTOR TRUE
EXIT AUTOMATIC
LAYOUT XPOS 300 YPOS 300
NAME_POSITION XPOS 300 YPOS 225
PRIORITY DEFINED_IN INPUT_CONTAINER
PROGRAM 'UPES_Program'
PROGRAM_EXECUTION_UNIT 'UPES.FMCSYS.FMCGRP'
SYNCHRONIZATION CHAINED
END 'Program1'
PROGRAM_ACTIVITY 'Program2' ( 'a1', 'a1' )
START AUTOMATIC WHEN AT_LEAST_ONE CONNECTOR TRUE
EXIT AUTOMATIC
LAYOUT XPOS 300 YPOS -500
NAME_POSITION XPOS 300 YPOS -575
PRIORITY DEFINED_IN INPUT_CONTAINER
PROGRAM 'UPES_Program'
PROGRAM_EXECUTION_UNIT 'UPES.FMCSYS.FMCGRP'
SYNCHRONIZATION CHAINED
END 'Program2'
CONTROL
FROM 'DummyApp' TO 'Process'
WHEN "a1[3].name NOT NULL"
XPOS -172 YPOS -615
LAYOUT
XPOS -100 YPOS -700
CONTROL
FROM 'DummyApp' TO 'Program'
WHEN "a1[1].name NOT NULL"
XPOS -100 YPOS -25
LAYOUT
XPOS -100 YPOS 0
CONTROL
FROM 'DummyApp' TO 'Program1'
WHEN "a1[0].name NOT NULL"
XPOS -135 YPOS 150
LAYOUT
XPOS -100 YPOS 200
CONTROL
FROM 'DummyApp' TO 'Program2'
WHEN "a1[2].name NOT NULL"
XPOS -85 YPOS -298
LAYOUT
XPOS 0 YPOS -300
DATA
FROM SOURCE 1 TO 'DummyApp'
MAP '_STRUCT' TO '_STRUCT'
DATA
FROM 'DummyApp' TO 'Program1'
MAP 'a1(0)' TO '_STRUCT'
DATA
FROM 'DummyApp' TO 'Program'
MAP 'a1(1)' TO '_STRUCT'
DATA
FROM 'DummyApp' TO 'Program2'
MAP 'a1(2)' TO '_STRUCT'
DATA
FROM 'DummyApp' TO 'Process'
MAP 'a1(3)' TO 'a1(0)'
MAP 'a1(4)' TO 'a1(1)'
DATA
DEFAULT 'DummyApp'
MAP '_STRUCT' TO '_STRUCT'
LAYOUT
XPOS -600 YPOS 100
XPOS -400 YPOS 100
END 'RecursionTest'

[/url]
Back to top
View user's profile Send private message
jmac
PostPosted: Tue Feb 18, 2003 7:05 am    Post subject: Reply with quote

Jedi Knight

Joined: 27 Jun 2001
Posts: 3081
Location: EmeriCon, LLC

jk:

What you are trying to implement is known to me as a "Bundle". This construct was supported in FlowMark (MQWF predecessor), but not in MQWF.

We (SYSCOM Inc.) have been kicking around implementations of this construct for a long time. At this point we have not been able to implement a successful "general purpose" bundle. In your situation (with a given number of subprocesses to generate) this may be possible, but it will definitely require some work. I would think about somehow passing to each subprocess the "Index" of which reply field to use. I am sure that by now you have realized that getting the data to the "bundle" subprocesses is the easy part, its getting the results back thats difficult. I am in no way certain that this would work for you......

GOOD LUCK.
_________________
John McDonald
RETIRED
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
yaakovd
PostPosted: Tue Feb 18, 2003 2:12 pm    Post subject: Reply with quote

Partisan

Joined: 20 Jan 2003
Posts: 319
Location: Israel

jmac wrote:
getting the results back thats difficult.

But it possible. I worked with this kind of recursion in past. If you close (not terminate) recursion subprocesses, you can map process output container back to main process.

In process 'RecursionTest' change output data from Default to 'A_PersonInfo' and map it. May be you need mapping for "reject" only?
_________________
Best regards.
Yaakov
SWG, IBM Commerce, Israel
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » Workflow Engines - IBM MQ Workflow & Business Process Choreographer » Recursion
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.