public interface MessagePublisher
extends java.lang.AutoCloseable
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes the publisher by closing its underlying channel.
|
void |
publish(java.lang.Object event,
EventPublisher.PublisherConfiguration publisherConfiguration)
Publishes the given event using the given publisher configuration template.
|
void publish(java.lang.Object event,
EventPublisher.PublisherConfiguration publisherConfiguration)
throws java.io.IOException,
java.util.concurrent.TimeoutException
event - the event being published to RabbitMQpublisherConfiguration - the default publisher configurationjava.io.IOException - if the channel can not be opened correctly or the actual send fails.java.util.concurrent.TimeoutException - if a timeout while sending occursvoid close()
throws java.io.IOException,
java.util.concurrent.TimeoutException
close in interface java.lang.AutoCloseablejava.io.IOException - if the channel cannot be closed correctly. Usually occurs when the channel
is already closing or is already closed.java.util.concurrent.TimeoutException - if a timeout occurs while closing the publisher.