Package interlok.rabbitmq
Class ExplicitQueue
- java.lang.Object
-
- interlok.rabbitmq.ExplicitQueue
-
- All Implemented Interfaces:
Declaration.QueueDeclaration
@ComponentProfile(summary="Explicitly declare a RabbitMQ Queue before use", since="4.3.0") public class ExplicitQueue extends java.lang.Object implements Declaration.QueueDeclarationExplicitly configured Queue declaration.Depending on your RabbitMQ Configuration you may wish to explicitly declare a queue before use. In the absence of any other configuration Interlok assumes that queues should be durable, non-exclusive and should not be automatically deleted if not in use. If your expectations are different then you should definitely configure one of these.
This implementation does not support queue declaration arguments (these are are a
Map<String, Object>which is hard to support in configuration).
-
-
Constructor Summary
Constructors Constructor Description ExplicitQueue()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddeclare(com.rabbitmq.client.Channel ch, java.lang.String name)Declare the queue.java.lang.BooleangetAutoDelete()Whether or not the queue is deleted when no longer in use.java.lang.BooleangetDurable()Whether or not the queue should survive a server restart.java.lang.BooleangetExclusive()Whether or not the queue is exlusive to the connection.voidsetAutoDelete(java.lang.Boolean autoDelete)Whether or not the queue is deleted when no longer in use.voidsetDurable(java.lang.Boolean durable)Whether or not the queue should survive a server restart.voidsetExclusive(java.lang.Boolean exclusive)Whether or not the queue is exlusive to the connection.
-
-
-
Method Detail
-
declare
public void declare(com.rabbitmq.client.Channel ch, java.lang.String name) throws java.lang.ExceptionDescription copied from interface:Declaration.QueueDeclarationDeclare the queue.- Specified by:
declarein interfaceDeclaration.QueueDeclaration- Parameters:
ch- the channel to use to declare the queue.name- the name of the queue.- Throws:
java.lang.Exception
-
getDurable
public java.lang.Boolean getDurable()
Whether or not the queue should survive a server restart.
-
setDurable
public void setDurable(java.lang.Boolean durable)
Whether or not the queue should survive a server restart.
-
getExclusive
public java.lang.Boolean getExclusive()
Whether or not the queue is exlusive to the connection.
-
setExclusive
public void setExclusive(java.lang.Boolean exclusive)
Whether or not the queue is exlusive to the connection.
-
getAutoDelete
public java.lang.Boolean getAutoDelete()
Whether or not the queue is deleted when no longer in use.
-
setAutoDelete
public void setAutoDelete(java.lang.Boolean autoDelete)
Whether or not the queue is deleted when no longer in use.
-
-