Class TemporaryQueueExecutor

java.lang.Object
org.apache.jmeter.protocol.jms.sampler.TemporaryQueueExecutor
All Implemented Interfaces:
QueueExecutor

public class TemporaryQueueExecutor extends Object implements QueueExecutor
Request/reply executor with a temporary reply queue.
Used by JMS Sampler (Point to Point)
  • Constructor Details

    • TemporaryQueueExecutor

      public TemporaryQueueExecutor(javax.jms.QueueSession session, javax.jms.Queue destination, int timeoutMs) throws javax.jms.JMSException
      Constructor.
      Parameters:
      session - the session to use to send the message
      destination - the queue to send the message on
      timeoutMs - Timeout in millis
      Throws:
      javax.jms.JMSException - when internally used QueueRequestor can not be constructed with session and destination
  • Method Details

    • sendAndReceive

      public javax.jms.Message sendAndReceive(javax.jms.Message request, int deliveryMode, int priority, long expiration) throws javax.jms.JMSException
      Sends and receives a message.
      Specified by:
      sendAndReceive in interface QueueExecutor
      Parameters:
      request - the message to send
      deliveryMode - the delivery mode to use
      priority - the priority for this message
      expiration - messages lifetime in ms
      Returns:
      the received message or null
      Throws:
      javax.jms.JMSException - in case of an exception from the messaging system
    • close

      public void close() throws javax.jms.JMSException
      Description copied from interface: QueueExecutor
      Close the resources
      Specified by:
      close in interface QueueExecutor
      Throws:
      javax.jms.JMSException - in case of an exception from the messaging system