Forum Discussion

kalyanmudi's avatar
New Contributor
12 years ago

Mocking JMS reply-response (using temp queue)

I have a Tibco component that publishes message onto a queue to be subscribed by component X. Component X processes that message and then sends back a response. The response is received by a temporary queue. This temporary queue name is set in JMSReplyTo property of input message. Tibco component receives the response from the temp queue and moves on.

I need to test the Tibco component and hence need to create a mock of component X. I don't apparently seem to find anything related to whether soap ui supports sending response to a temp queue.

Has anyone tried this? Or, Is anyone aware this particular kind of mock service can be build using soap ui?

Thanks in advance.


4 Replies

  • nmrao's avatar
    Champion Level 3
    1. Have you successfully configured Hermes in soapui?
    2. Do you want say, need to listen to queue. Little bit confusing on seeing the phrase "subscribing to queue". Subscribe is used to for topics.
    3. Are you using SOAP over JMS? or its a plan jms message?
    4. Have successful sending a SOAP message to JMS and getting reply back. However, not the case sending a plain jms message. You may need to custom code for this, I guess.

    Would you please explain your use case a bit more clear?
    • Shadab_Rizvi's avatar

      Hi ,


      Need help in creating a scenario .


      Scenario : I have 2 ApacheMQ queues :


      1. RegisterRequest

      2. RegisterResponse


      Have configured Hermes and created the queues in it using ApacheMQ connection factory.


      What i want is :

      1. Feed xml text from ApacheMQ UI , into RegisterRequest .

      2. Input to be recieved in Hermes .

      3. XML to be taken as input by the Mock service created .

      4. Response sent back to RegisterResponse .


      Right now i am adding JMS endpoint with 1 queue under recieve and another under send , and using that JMS endpoint in request Window.

      What i am observing is that the request itself is being sent back in the response.


      Can you help me create this scenario ..

  • kalyanmudi's avatar
    New Contributor
    Hi, Thanks for your response.

    1. Yes I have successfully configured Hermes in soapui. Also, I could send a raw xml message to an ems queue using jms endpoint that I have created in soapui with help of hermes config.

    2. Apologies for the terminology. Yes, I wanted to listen to queue.

    3. Its a plain/raw xml message.

    Component that I want to test: Lets say Y. It receives an initial xml message from a jms queue (sent by component X), does some processing. Then, it sends a update message to another jms queue (ultimately to component X). While sending this update message to the queue, it adds a JMSReplyTo property with a temporary queue name and also creates that temporary queue expecting a response from Component X on this.

    I want to test Component Y using soap-ui and want to mock the activities of Component X. I have been able to send the initial one way xml message to the Comp Y. Now, I need to be able to - using soapui - to receive the update message sent by Comp Y on a queue and then - send (from soapui) a response message on 'temporary queue' that is in update message's JMSReplyTo property. I am not sure if I can simulate this in soapui. From soapui perspective, it's not exactly request-response, but receive request - send response and that too on a temprary queue.

    Please let me know if the above clarifies or need further information.

  • nmrao's avatar
    Champion Level 3
    Thank you for the clarification.
    I do not see any webservices involved in the case that is explained. You could do using java/groovy and optionally transform xml message in component Y using stylesheet.