Discussion:
Stop iterator if it is sitting and waiting for the next connection....
(too old to reply)
bill valvik
2020-11-09 19:39:53 UTC
Permalink
I have an AL with a iterator connected to an IBM MQ. I want to try to set this to run only once and then quit. I then have a schedule restart it every 5 minutes.

I have everything configured and it working properly however when it starts on once of the timer intervals and nothing is pending from the MQ the iterator just sits and eventually will lose the connection.

Is there code that could detect the AL running and just sitting on the iterator and close/end/abort the AL so it will restart on the next scheduled interval?

I am still looking into alternate solutions to solve the MQ disconnect however looking at this option as well.

Thank you for your help.


Bill
Jens Thomassen
2020-11-11 08:11:22 UTC
Permalink
If you are using the IBM MQ Series Connector, it has a "GetNext Timeout" parameter in the Advanced section.
This specifies the number of milliseconds the connector should wait for a new Entry.
Please try to set that to a number you like, e.g. 1000 for one second.
If nothing has arrived within that time, the AL will stop.

Continue reading on narkive:
Loading...