Class WmClusterMultiSendQueueSenderImpl
- java.lang.Object
-
- com.webmethods.locks.Node
-
- com.webmethods.jms.impl.WmMessageProducerImpl
-
- com.webmethods.jms.impl.WmQueueSenderImpl
-
- com.webmethods.jms.loadbalance.connection.WmClusterMultiSendQueueSenderImpl
-
- All Implemented Interfaces:
WmMessageProducer
,WmQueueSender
,javax.jms.MessageProducer
,javax.jms.QueueSender
public class WmClusterMultiSendQueueSenderImpl extends WmQueueSenderImpl
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Random
random
-
Fields inherited from class com.webmethods.jms.impl.WmMessageProducerImpl
_destination, _logApi, _session
-
Fields inherited from class com.webmethods.locks.Node
_lockManager
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
WmClusterMultiSendQueueSenderImpl(WmClusterXASessionImpl session, WmQueueImpl destination)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getPrimaryBrokerForMultiSend()
void
send(javax.jms.Message message)
Sends a message using theMessageProducer
's default delivery mode, priority, and time to live.void
send(javax.jms.Message message, int deliveryMode, int priority, long timeToLive)
Sends a message to the destination, specifying delivery mode, priority, and time to live.void
send(javax.jms.Queue destination, javax.jms.Message message)
Sends a message to a queue for an unidentified message producer.void
send(javax.jms.Queue destination, javax.jms.Message message, int deliveryMode, int priority, long timeToLive)
Sends a message to a queue for an unidentified message producer, specifying delivery mode, priority and time to live.-
Methods inherited from class com.webmethods.jms.impl.WmQueueSenderImpl
getQueue, send, send
-
Methods inherited from class com.webmethods.jms.impl.WmMessageProducerImpl
checkState, close, deliveryModeToString, getCompressionLevel, getCompressionThreshold, getDeliveryMode, getDestination, getDisableMessageID, getDisableMessageTimestamp, getOutputStream, getOutputStream, getPriority, getTimeToLive, nextMessageIdentifier, reconnect, send, send, send, send, send, send, setCompressionLevel, setCompressionThreshold, setDeliveryMode, setDisableMessageID, setDisableMessageTimestamp, setPriority, setTimeToLive, toString
-
Methods inherited from class com.webmethods.locks.Node
getLockManager, getParent
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface javax.jms.MessageProducer
close, getDeliveryMode, getDestination, getDisableMessageID, getDisableMessageTimestamp, getPriority, getTimeToLive, send, send, setDeliveryMode, setDisableMessageID, setDisableMessageTimestamp, setPriority, setTimeToLive
-
Methods inherited from interface com.webmethods.jms.WmMessageProducer
getCompressionLevel, getCompressionThreshold, getOutputStream, getOutputStream, send, send, send, send, setCompressionLevel, setCompressionThreshold
-
-
-
-
Constructor Detail
-
WmClusterMultiSendQueueSenderImpl
protected WmClusterMultiSendQueueSenderImpl(WmClusterXASessionImpl session, WmQueueImpl destination)
-
-
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 interfacejavax.jms.QueueSender
- Overrides:
send
in classWmQueueSenderImpl
- Parameters:
destination
- the queue to send this message tomessage
- the message to senddeliveryMode
- the delivery mode to usepriority
- the priority for this messagetimeToLive
- 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 theMessageProducer
's default delivery mode, priority, and time to live.- Specified by:
send
in interfacejavax.jms.MessageProducer
- Specified by:
send
in interfacejavax.jms.QueueSender
- Overrides:
send
in classWmMessageProducerImpl
- 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 aMessageProducer
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 interfacejavax.jms.MessageProducer
- Specified by:
send
in interfacejavax.jms.QueueSender
- Overrides:
send
in classWmMessageProducerImpl
- Parameters:
message
- the message to senddeliveryMode
- the delivery mode to usepriority
- the priority for this messagetimeToLive
- 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 aMessageProducer
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 theQueueSender
'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 interfacejavax.jms.QueueSender
- Overrides:
send
in classWmQueueSenderImpl
- Parameters:
destination
- the queue to send this message tomessage
- 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()
-
-