Top Description Fields Constructors Methods
org.springframework.jms.connection

pack-priv Class CachedMessageProducer

extends Object
implements MessageProducer, QueueSender, TopicPublisher
Class Inheritance
All Implemented Interfaces
jakarta.jms.TopicPublisher, jakarta.jms.MessageProducer, java.lang.AutoCloseable, jakarta.jms.QueueSender
Imports
jakarta.jms.CompletionListener, .Destination, .JMSException, .Message, .MessageProducer, .Queue, .QueueSender, .Topic, .TopicPublisher, org.springframework.lang.Nullable

JMS MessageProducer decorator that adapts calls to a shared MessageProducer instance underneath, managing QoS settings locally within the decorator.
Author
Juergen Hoeller
Since
2.5.3

Field Summary

Modifier and TypeField and Description
private int
private Long
private Boolean
private Boolean
private int
private final MessageProducer
private long

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
close()

Implements jakarta.jms.MessageProducer.close.

Closes the message producer.

public long
getDeliveryDelay()

Implements jakarta.jms.MessageProducer.getDeliveryDelay.

Gets the minimum length of time in milliseconds that must elapse after a message is sent before the Jakarta Messaging provider may deliver the message to a consumer.

public int
getDeliveryMode()

Implements jakarta.jms.MessageProducer.getDeliveryMode.

Gets the producer's default delivery mode.

public Destination
getDestination()

Implements jakarta.jms.MessageProducer.getDestination.

Gets the destination associated with this MessageProducer.

public boolean
getDisableMessageID()

Implements jakarta.jms.MessageProducer.getDisableMessageID.

Gets an indication of whether message IDs are disabled.

public boolean
getDisableMessageTimestamp()

Implements jakarta.jms.MessageProducer.getDisableMessageTimestamp.

Gets an indication of whether message timestamps are disabled.

public int
getPriority()

Implements jakarta.jms.MessageProducer.getPriority.

Gets the producer's default priority.

public Queue
getQueue()

Implements jakarta.jms.QueueSender.getQueue.

Gets the queue associated with this QueueSender.

public long
getTimeToLive()

Implements jakarta.jms.MessageProducer.getTimeToLive.

Gets the default length of time in milliseconds from its dispatch time that a produced message should be retained by the message system.

public Topic
getTopic()

Implements jakarta.jms.TopicPublisher.getTopic.

Gets the topic associated with this TopicPublisher.

public void
publish(Message
the message to publish
message
)

Implements jakarta.jms.TopicPublisher.publish.

Publishes a message to the topic.

public void
publish(Message
the message to publish
message
,
int
the delivery mode to use
deliveryMode
,
int
the priority for this message
priority
,
long
the message's lifetime (in milliseconds)
timeToLive
)

Implements jakarta.jms.TopicPublisher.publish.

Publishes a message to the topic, specifying delivery mode, priority, and time to live.

public void
publish(Topic
the topic to publish this message to
topic
,
Message
the message to publish
message
)

Implements jakarta.jms.TopicPublisher.publish.

Publishes a message to a topic for an unidentified message producer.

public void
publish(Topic
the topic to publish this message to
topic
,
Message
the message to publish
message
,
int
the delivery mode to use
deliveryMode
,
int
the priority for this message
priority
,
long
the message's lifetime (in milliseconds)
timeToLive
)

Implements jakarta.jms.TopicPublisher.publish.

Publishes a message to a topic for an unidentified message producer, specifying delivery mode, priority and time to live.

public void
send(Message
the message to send
message
)

Implements jakarta.jms.MessageProducer.send, jakarta.jms.QueueSender.send.

Sends a message using the MessageProducer's default delivery mode, priority, and time to live.

public void
send(Message
the message to send
message
,
int
the delivery mode to use
deliveryMode
,
int
the priority for this message
priority
,
long
the message's lifetime (in milliseconds)
timeToLive
)

Implements jakarta.jms.MessageProducer.send, jakarta.jms.QueueSender.send.

Sends a message, specifying delivery mode, priority, and time to live.

public void
send(Destination
the destination to send this message to
destination
,
Message
the message to send
message
)

Implements jakarta.jms.MessageProducer.send.

Sends a message to a destination for an unidentified message producer using the MessageProducer's default delivery mode, priority, and time to live.

public void
send(Destination
the destination to send this message to
destination
,
Message
the message to send
message
,
int
the delivery mode to use
deliveryMode
,
int
the priority for this message
priority
,
long
the message's lifetime (in milliseconds)
timeToLive
)

Implements jakarta.jms.MessageProducer.send.

Sends a message to a destination for an unidentified message producer, specifying delivery mode, priority and time to live.

public void
send(Message
the message to send
message
,
CompletionListener
a CompletionListener to be notified when the send has completed
completionListener
)

Implements jakarta.jms.MessageProducer.send.

Sends a message using the MessageProducer's default delivery mode, priority, and time to live, performing part of the work involved in sending the message in a separate thread and notifying the specified CompletionListener when the operation has completed.

public void
send(Message
the message to send
message
,
int
the delivery mode to use
deliveryMode
,
int
the priority for this message
priority
,
long
the message's lifetime (in milliseconds)
timeToLive
,
CompletionListener
a CompletionListener to be notified when the send has completed
completionListener
)

Implements jakarta.jms.MessageProducer.send.

Sends a message, specifying delivery mode, priority and time to live, performing part of the work involved in sending the message in a separate thread and notifying the specified CompletionListener when the operation has completed.

public void
send(Destination
the destination to send this message to
destination
,
Message
the message to send
message
,
CompletionListener
a CompletionListener to be notified when the send has completed
completionListener
)

Implements jakarta.jms.MessageProducer.send.

Sends a message to a destination for an unidentified message producer, using the MessageProducer's default delivery mode, priority, and time to live, performing part of the work involved in sending the message in a separate thread and notifying the specified CompletionListener when the operation has completed.

public void
send(Destination
the destination to send this message to
destination
,
Message
the message to send
message
,
int
the delivery mode to use
deliveryMode
,
int
the priority for this message
priority
,
long
the message's lifetime (in milliseconds)
timeToLive
,
CompletionListener
a CompletionListener to be notified when the send has completed
completionListener
)

Implements jakarta.jms.MessageProducer.send.

Sends a message to a destination for an unidentified message producer, specifying delivery mode, priority and time to live, performing part of the work involved in sending the message in a separate thread and notifying the specified CompletionListener when the operation has completed.

public void
send(Queue
the queue to send this message to
queue
,
Message
the message to send
message
)

Implements jakarta.jms.QueueSender.send.

Sends a message to a queue for an unidentified message producer.

public void
send(Queue
the queue to send this message to
queue
,
Message
the message to send
message
,
int
the delivery mode to use
deliveryMode
,
int
the priority for this message
priority
,
long
the message's lifetime (in milliseconds)
timeToLive
)

Implements jakarta.jms.QueueSender.send.

Sends a message to a queue for an unidentified message producer, specifying delivery mode, priority and time to live.

public void
setDeliveryDelay(long
the delivery delay in milliseconds.
deliveryDelay
)

Implements jakarta.jms.MessageProducer.setDeliveryDelay.

Sets the minimum length of time in milliseconds that must elapse after a message is sent before the Jakarta Messaging provider may deliver the message to a consumer.

public void
setDeliveryMode(int
the message delivery mode for this message producer; legal values are DeliveryMode.NON_PERSISTENT and DeliveryMode.PERSISTENT
deliveryMode
)

Implements jakarta.jms.MessageProducer.setDeliveryMode.

Sets the producer's default delivery mode.

public void
setDisableMessageID(boolean
indicates if message IDs may be disabled
disableMessageID
)

Implements jakarta.jms.MessageProducer.setDisableMessageID.

Specify whether message IDs may be disabled.

public void
setDisableMessageTimestamp(boolean
indicates whether message timestamps may be disabled
disableMessageTimestamp
)

Implements jakarta.jms.MessageProducer.setDisableMessageTimestamp.

Specify whether message timestamps may be disabled.

public void
setPriority(int
the message priority for this message producer; must be a value between 0 and 9
priority
)

Implements jakarta.jms.MessageProducer.setPriority.

Sets the producer's default priority.

public void
setTimeToLive(long
the message time to live in milliseconds; zero is unlimited
timeToLive
)

Implements jakarta.jms.MessageProducer.setTimeToLive.

Sets the default length of time in milliseconds from its dispatch time that a produced message should be retained by the message system.

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait