Class WmClusterMultiSendQueueSenderImpl

    • Field Detail

      • random

        protected java.util.Random random
    • Method Detail

      • send

        public void send​(javax.jms.Queue destination,
                         javax.jms.Message message,
                         int deliveryMode,
                         int priority,
                         long timeToLive)
                  throws javax.jms.JMSException
        Description copied from class: WmQueueSenderImpl
        Sends a message to a queue for an unidentified message producer, specifying delivery mode, priority and time to live.

        Typically, a message producer is assigned a queue at creation time; however, the JMS API also supports unidentified message producers, which require that the queue be supplied every time a message is sent.

        Specified by:
        send in interface javax.jms.QueueSender
        Overrides:
        send in class WmQueueSenderImpl
        Parameters:
        destination - the queue to send this message to
        message - the message to send
        deliveryMode - the delivery mode to use
        priority - the priority for this message
        timeToLive - the message's lifetime (in milliseconds)
        Throws:
        javax.jms.JMSException - if the JMS provider fails to send the message due to some internal error.
        javax.jms.MessageFormatException - if an invalid message is specified.
        javax.jms.InvalidDestinationException - if a client uses this method with an invalid queue.
      • send

        public void send​(javax.jms.Message message)
                  throws javax.jms.JMSException
        Description copied from class: WmMessageProducerImpl
        Sends a message using the MessageProducer's default delivery mode, priority, and time to live.
        Specified by:
        send in interface javax.jms.MessageProducer
        Specified by:
        send in interface javax.jms.QueueSender
        Overrides:
        send in class WmMessageProducerImpl
        Parameters:
        message - the message to send
        Throws:
        javax.jms.JMSException - if the JMS provider fails to send the message due to some internal error.
        javax.jms.MessageFormatException - if an invalid message is specified.
        javax.jms.InvalidDestinationException - if a client uses this method with a MessageProducer with an invalid destination.
        See Also:
        Session.createProducer(javax.jms.Destination), MessageProducer
      • send

        public void send​(javax.jms.Message message,
                         int deliveryMode,
                         int priority,
                         long timeToLive)
                  throws javax.jms.JMSException
        Description copied from class: WmMessageProducerImpl
        Sends a message to the destination, specifying delivery mode, priority, and time to live.
        Specified by:
        send in interface javax.jms.MessageProducer
        Specified by:
        send in interface javax.jms.QueueSender
        Overrides:
        send in class WmMessageProducerImpl
        Parameters:
        message - the message to send
        deliveryMode - the delivery mode to use
        priority - the priority for this message
        timeToLive - the message's lifetime (in milliseconds)
        Throws:
        javax.jms.JMSException - if the JMS provider fails to send the message due to some internal error.
        javax.jms.MessageFormatException - if an invalid message is specified.
        javax.jms.InvalidDestinationException - if a client uses this method with a MessageProducer with an invalid destination.
        See Also:
        Session.createProducer(javax.jms.Destination)
      • send

        public void send​(javax.jms.Queue destination,
                         javax.jms.Message message)
                  throws javax.jms.JMSException
        Description copied from class: WmQueueSenderImpl
        Sends a message to a queue for an unidentified message producer. Uses the QueueSender's default delivery mode, priority, and time to live.

        Typically, a message producer is assigned a queue at creation time; however, the JMS API also supports unidentified message producers, which require that the queue be supplied every time a message is sent.

        Specified by:
        send in interface javax.jms.QueueSender
        Overrides:
        send in class WmQueueSenderImpl
        Parameters:
        destination - the queue to send this message to
        message - the message to send
        Throws:
        javax.jms.JMSException - if the JMS provider fails to send the message due to some internal error.
        javax.jms.MessageFormatException - if an invalid message is specified.
        javax.jms.InvalidDestinationException - if a client uses this method with an invalid queue.
        See Also:
        MessageProducer.getDeliveryMode(), MessageProducer.getTimeToLive(), MessageProducer.getPriority()
      • getPrimaryBrokerForMultiSend

        public int getPrimaryBrokerForMultiSend()