In the previous post we talk about one feature (the format-dateTime XPath function) which behavior on TIBCO BusinessWorks 6 wasn’t the same that on BusinessWorks 5, but today we are going to talk about another similar situation.
On BusinessWorks 5 it was usual to have Dynamic Call Processes, so you could invoke one SubPorcess or another depending on the data you have on real-time. This features is present on the BusinessWorks 6 version but to do that it’s not that easy or, at least, are not the same set of steps you have to do.
So, today, we are going to explain how to perform a dynamic call process on TIBCO BusinessWorks. To do that, we need these requirements:
- A master process with the Invoke / Call Process activity.
- A few Child processes with the same WSDL.
In my example, we are going to go forward with this master process or parent process:
And with three child processes that only perform a Log activity to show the text “I’m ChildX” and X goes from A to C:
Ok, that seems simple, but how does it works? Ok. These are the things you should be aware of:
- All the Child processes should use the same WSDL because they need to have the same interfaces.
- All the Child processes should have a unique service name identifier, because this identifier is one of the part the engine is going to use to find the right child process:
- All the Child processes interfaces should be registered in the Service Registry. You should be sure that the check labeled: “Register with Service Registry” as you can see here:
- The parent process should add a Set EPR activity with the follow input configuration:
The first two arguments are the same because they belong to the BW Process project and the last value are the way you are going to determinate the Interface Name of the Child Process you are going to invoke. In our example are ChildA , ChildB and ChildC and we are using an input value to choose between all the possible values.
And that’s it! Now, you only have to deploy and test your process and your are going to have an output similar to this, depending on the invocations you were doing:
As always, you can take a look at the source code in our GitHub repo.