0

My goal is to implement a number of ActiveMQ JMS tests via SoapUI. In order to do so, I have established a connection via (the) Hermes JMS (frontend). My issue now is to not consume the oldest message in the queue, but to consume the newest / latest one, i.e. the one whose outcome I am respectively testing as a result of my latest Soap request. Currently it is the prior one that is implemented by default.

As such, is there something comparable to a QueueBrowser or something similar in terms of my SoapUI JMS Request? I also took a look at filters, but I do not come to any feasible solution.

Would the only way to get to my desired result be to transfer my SoapUI JMS request into code, integrate the QueueBrowser and run it as a Groovy script? I hope not - for maintenance resons, I am trying to keep the whole setup as less technical as possible, hence, no code but only configuration is the desired state.

I'd like to thank you very much in advance!

noai
  • 31
  • 1
  • 4
  • Is there a way to set the message selector to only retrieve the newest / latest message based on the header attribute `JMSTimestamp`? – noai Jul 26 '19 at 15:03
  • I have the paid version of SoapUI (Ready-API). In my experience their support, including technical support, of JMS is very poor. I was only able to incorporate JMS testing through Groovy scripts. – SiKing Jul 29 '19 at 15:37
  • My current solution is to go via a Groovy script, implementing a QueueBrowser. I am going through the queued messages, checking them for my validation criteria, which usually correlates with it being the newest one. Furthermore, I extract its message ID and then resume to the next Soap Request test step, in which I combine message ID and slector, to consume the aspired message under test. – noai Jul 30 '19 at 08:59
  • My attempts to hook up RabbitMQ: https://github.com/rabbitmq/rabbitmq-tutorials/tree/master/soapui – SiKing Jul 30 '19 at 14:25
  • The order to process older messages is a constraint of the JMS specification. In your case, as you seems to mix testing messages with valid message, I would recommend to set a JMSHeader like "test=true" and using a selector from your test consumer. In our case we did another solution: we set the topic mirroring for all queues and the test (Junit) was checking if the message is received in the topic, that way you let the real consumer to take the message and the test is not dependent from the other consumer taking the test message. – рüффп Oct 30 '19 at 22:24

0 Answers0