Package org.ow2.joram.mom.amqp
Class StubAgentIn
- java.lang.Object
-
- org.ow2.joram.mom.amqp.StubAgentIn
-
public class StubAgentIn extends Object
TheStubAgentInclass handles input interactions with other Joram AMQP servers.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classStubAgentIn.Null
-
Field Summary
Fields Modifier and Type Field Description private static Loggerloggerloggerprivate static StubAgentIn.NullnullResponse
-
Constructor Summary
Constructors Constructor Description StubAgentIn()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description private static voidaddBoundExchange(AddBoundExchange request, short serverId, long proxyId)static voidbasicAck(String queueName, List<Long> idsToAck)static BooleanbasicCancel(String consumerTag, String queueName, int channelNumber, short serverId, long proxyId)static voidbasicConsume(AMQP.Basic.Consume basicConsume, short serverId, long proxyId)static MessagebasicGet(AMQP.Basic.Get basicGet, short serverId, long proxyId)static voidbasicPublish(PublishRequest publishRequest, short serverId, long proxyId)static voidbasicRecover(String queueName, List<Long> idsToRecover)private static ObjectdoProcessMethod(AbstractMarshallingMethod method, short serverId, long proxyId)static voidexchangeDeclare(AMQP.Exchange.Declare exchangeDeclare)static voidexchangeDelete(AMQP.Exchange.Delete exchangeDelete)static voidprocessRequest(AgentId from, long keyLock, long proxyId, Object request)static voidprocessResponse(AgentId from, long keyLock, Object response)private static voidpublishToQueue(PublishToQueue request)static voidqueueBind(AMQP.Queue.Bind queueBind, short serverId, long proxyId)static AMQP.Queue.DeclareOkqueueDeclare(AMQP.Queue.Declare queueDeclare, short serverId, long proxyId)static AMQP.Queue.DeleteOkqueueDelete(AMQP.Queue.Delete queueDelete, short serverId, long proxyId)static AMQP.Queue.PurgeOkqueuePurge(AMQP.Queue.Purge queuePurge, short serverId, long proxyId)static voidqueueUnbind(AMQP.Queue.Unbind queueUnbind, short serverId, long proxyId)private static voidremoveBoundExchange(RemoveBoundExchange request, short serverId, long proxyId)private static voidremoveQueueBindings(RemoveQueueBindings request)
-
-
-
Field Detail
-
logger
private static final Logger logger
logger
-
nullResponse
private static StubAgentIn.Null nullResponse
-
-
Method Detail
-
processResponse
public static void processResponse(AgentId from, long keyLock, Object response)
- Parameters:
from-keyLock-response-
-
processRequest
public static void processRequest(AgentId from, long keyLock, long proxyId, Object request)
- Parameters:
from-keyLock-request-
-
doProcessMethod
private static Object doProcessMethod(AbstractMarshallingMethod method, short serverId, long proxyId) throws AMQPException
- Parameters:
method-- Throws:
ExceptionAMQPException
-
removeQueueBindings
private static void removeQueueBindings(RemoveQueueBindings request) throws TransactionException
- Throws:
TransactionException
-
addBoundExchange
private static void addBoundExchange(AddBoundExchange request, short serverId, long proxyId) throws ResourceLockedException, TransactionException
-
publishToQueue
private static void publishToQueue(PublishToQueue request) throws TransactionException
- Throws:
TransactionException
-
removeBoundExchange
private static void removeBoundExchange(RemoveBoundExchange request, short serverId, long proxyId) throws ResourceLockedException
- Throws:
ResourceLockedException
-
basicCancel
public static Boolean basicCancel(String consumerTag, String queueName, int channelNumber, short serverId, long proxyId) throws NotFoundException, ResourceLockedException, PreconditionFailedException, TransactionException
-
basicConsume
public static void basicConsume(AMQP.Basic.Consume basicConsume, short serverId, long proxyId) throws NotFoundException, ResourceLockedException, AccessRefusedException
-
basicGet
public static Message basicGet(AMQP.Basic.Get basicGet, short serverId, long proxyId) throws NotFoundException, ResourceLockedException, TransactionException
-
basicPublish
public static void basicPublish(PublishRequest publishRequest, short serverId, long proxyId) throws NotFoundException
- Throws:
NotFoundException
-
basicRecover
public static void basicRecover(String queueName, List<Long> idsToRecover) throws TransactionException
- Throws:
TransactionException
-
exchangeDeclare
public static void exchangeDeclare(AMQP.Exchange.Declare exchangeDeclare) throws CommandInvalidException, PreconditionFailedException, NotAllowedException, NotFoundException, AccessRefusedException
-
exchangeDelete
public static void exchangeDelete(AMQP.Exchange.Delete exchangeDelete) throws NotFoundException, PreconditionFailedException, AccessRefusedException
-
queueBind
public static void queueBind(AMQP.Queue.Bind queueBind, short serverId, long proxyId) throws NotFoundException, ResourceLockedException, TransactionException
-
queueDeclare
public static AMQP.Queue.DeclareOk queueDeclare(AMQP.Queue.Declare queueDeclare, short serverId, long proxyId) throws ResourceLockedException, NotFoundException, PreconditionFailedException, AccessRefusedException, TransactionException
-
queueDelete
public static AMQP.Queue.DeleteOk queueDelete(AMQP.Queue.Delete queueDelete, short serverId, long proxyId) throws NotFoundException, PreconditionFailedException, ResourceLockedException, TransactionException
-
queuePurge
public static AMQP.Queue.PurgeOk queuePurge(AMQP.Queue.Purge queuePurge, short serverId, long proxyId) throws NotFoundException, SyntaxErrorException, ResourceLockedException, TransactionException
-
queueUnbind
public static void queueUnbind(AMQP.Queue.Unbind queueUnbind, short serverId, long proxyId) throws NotFoundException, ResourceLockedException
-
-