|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
MQ REST API - Validate MQ Server Availability |
« View previous topic :: View next topic » |
Author |
Message
|
RHeunes |
Posted: Wed Feb 26, 2025 11:17 pm Post subject: MQ REST API - Validate MQ Server Availability |
|
|
Novice
Joined: 13 Sep 2021 Posts: 16
|
Hi,
I want to use the MQ REST API to validate that the MQ server is up before submitting transactions.
I tried the following to see Queue Manager status:
https://qaesb01:9443/ibmmq/rest/v2/admin/qmgr/QM01/
and get the following output:
{
"qmgr": [
{
"name": "QM01",
"state": "running"
}
]
}
This is fine, but I want to target the SVRCONN (APP.SVRCONN), I have had a look but I am not able to find a way to do it, does anyone know where I can find a reference for this or if it is possible.
Regards,
Rayn |
|
Back to top |
|
 |
bruce2359 |
Posted: Thu Feb 27, 2025 10:21 am Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
Why exactly do you need to target the svrconn channel? SVRCONN channels are only active when an app is connected. _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
RHeunes |
Posted: Thu Feb 27, 2025 11:57 pm Post subject: |
|
|
Novice
Joined: 13 Sep 2021 Posts: 16
|
Oh yeah that is not really gonna help, I guess qmgr will have to do then. However for interest sake you know of any reference guide for the REST API? |
|
Back to top |
|
 |
bruce2359 |
Posted: Fri Feb 28, 2025 10:21 am Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
|
Back to top |
|
 |
PeterPotkay |
Posted: Sun Mar 02, 2025 5:09 pm Post subject: Re: MQ REST API - Validate MQ Server Availability |
|
|
 Poobah
Joined: 15 May 2001 Posts: 7722
|
RHeunes wrote: |
Hi,
I want to use the MQ REST API to validate that the MQ server is up before submitting transactions.
|
Don't do this. Its a waste of time.
What are you gonna do if you check if the queue manager is up with REST, its says its up, and one millisecond after that it does down? What good is your up status? Its worthless. You are going to isse your transaction anyway and have to deal with the failed MQ call anyway.
What are you gonna do if you check if the queue manager is up with REST, its says its down, and one millisecond after that it actually comes back up? What good is your down status? Now you are wasting time not issuing the transaction that would have worked.
Just submit the transaction and check the MQ Reason Code that the queue manager returns on every single MQ API call you issue.
When you need to talk with your buddy on the phone, do you call your buddy to ask if he is ready to talk, hang up and then call right back to talk for reals? No, of course not. _________________ Peter Potkay
Keep Calm and MQ On |
|
Back to top |
|
 |
bruce2359 |
Posted: Sun Mar 02, 2025 7:28 pm Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
wholeheartedly with Mr. Potkay.
Same applies when pondering (inquiring) current queue depth to see if there are messages to consume. Merely do a get, then check ReasonCode. _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|