Forum Discussion

Reysha's avatar
New Contributor
3 years ago

How to clear queue messages from IBM MQ Client in higher ReadyAPI (3.1 and above) versions?



I'm trying to create a script to clear all messages from one or more queues.

I have some queues within IBM MQ explorer that needs to be cleared using a script so that I can use it run inside a test project. 

I have created a Groovy script that works for 3.0.0 version and below following this page:

But this supports only HermesJMS. Now for higher versions I have used JMS Manual Configuration in ReadyAPI

Here is my Queue config: 

How can I create a Groovy script or any step to clear messages from queue?



4 Replies

    • Reysha's avatar
      New Contributor

      Hello ebarbera ,


      Thank you for the response. But we are working for IBM MDM server which doesn't support AMQP atleast in our project. So could you please suggest any alternative so that all our JMS steps can be supported and queue can be cleared via a groovy script or some other step definition?