Creating FLOW Services dynamically

Dear fellows,

does anyone have a good idea on how to create Flow services dynamically at runtime ?

They should be based on a template service and be created with slightly different parameters by a service at runtime.

Thanks for any hint or idea.


Hi Rico,
Don’t know of a way to do this but curious as to what you are trying to accomplish with it? :confused:

I see different use cases for this, but the use case at hand is a slightly advanced publish-subscribe use case as follows:

I have an application publishing updates and an unknown number of consumers that expose the same “Update” Web Service (at different endpoints). The consumers can dynamically subscribe for the updates (createSubscription, suspend/resumeSubscription and removeSubscription). When the consuming applications create a new subscription, they start getting updates at the endpoint they register.

Now I can easily create/suspend/remove a trigger with the services in the pub.trigger directory, but I have not found a way to create a corresponding handler for the trigger which invokes the Update service at the correct endpoint.

The handler would be almost the same for all triggers, but should at least get the endpoint information to know where to invoke the Update service.

The current idea was to create the trigger and a trigger handler service for every new subscriber and setting the endpoint information at runtime for it.

If I use a generic handler for all the dynamically created triggers, I don’t know which endpoint this trigger represents. I have not found an easy way to find out from which trigger a particular service has been invoked at runtime.

Any better idea or approach to solve this is also appreciated.

Thanks much


Yep that is fairly advanced, some ideas off the top of my head. How about not trying to created multiple dynamic flow services based on subscriptions but use a meta data layer inside your update message to carry the subscribing endpoint information. One trigger and flow service then handles all the updates based upon the array of metadata endpoints. When they unsubscribe just remove it from the update messages.

The other idea is that it sounds like more of a task for an typical RSS feed. Kind of what is does out of the box. Subscribes can come and go at will without any advanced engineering required. Just some thoughts.

Thanks for the suggestions.

I had thought about the metadata layer. However, the issue is that the consumers are not always consuming at the same pace and can (individually) suspend/resume the subscription. Obviously, they should not lose any updates. With a metadata layer and a single trigger, I would have to manage the individual update queues for subscribers manually…

Don’t know much about RSS, sound like something to look at, don’t know whether it would support suspend/resume with queuing though.


Hi Rico,

Of course, you CAN create flow services using APIs provided by webMethods.
In the past I did create some predefined, small, utility services on the fly using com.wm.lang.flow.,,, com.wm.lang.ns. packages. But they are created only on D systems and also have predefined implementations with user defined inputs.

Your case seems to be different and I am wondering how you are going to maintain all those dynamically created services. Please share your updates on this.


Hi All,

I too have same requirement, please let me know how to create flow service dynamically.


Hi All,

Any update my request?