Posted: Tue Oct 07, 2014 1:59 am Post subject: HELP!! CMP API support for changing start mode of a flow
Newbie
Joined: 29 Sep 2014 Posts: 5
Not sure if this is the right category for the query...
We have a requirement to change the start mode property (Automatic, Manual, Maintained) of a message flow at runtime.
The CMP API has a class MessageFlowProxy which offers a method
public void setStartMode(java.lang.String newStartMode) for this purpose.
We are using the same to try to change the start mode of a flow from Manual to Maintained, but this doesn't seem to be working as expected. Even after setting the start mode for the flow with the below line of code, the start mode property of the flow remains Manual. Has someone tried this before and got this to work?? Appreciate any guidance offered!!!
Posted: Tue Oct 07, 2014 2:30 am Post subject: Re: HELP!! CMP API support for changing start mode of a flow
Grand Master
Joined: 22 May 2008 Posts: 1387 Location: Finland
Lichking1234 wrote:
but this doesn't seem to be working as expected. Even after setting the start mode for the flow with the below line of code, the start mode property of the flow remains Manual.
How do you check it? By calling .getStartMode() in the same program that changed it?
By defaut, these API calls return immediately without waiting for the broker to finish the task. So if you run your test before the value has really been changed, you may get the old value.
Try adding a line like this before the call to setStartMode():
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