public class AMQPSessionCallback extends Object implements SessionCallback
| Modifier and Type | Field and Description |
|---|---|
protected IDGenerator |
consumerIDGenerator |
| Constructor and Description |
|---|
AMQPSessionCallback(AMQPConnectionCallback protonSPI,
ProtonProtocolManager manager,
AMQPConnectionContext connection,
Connection transportConnection,
Executor executor,
org.apache.activemq.artemis.core.persistence.OperationContext operationContext) |
| Modifier and Type | Method and Description |
|---|---|
void |
ack(org.apache.activemq.artemis.core.transaction.Transaction transaction,
Object brokerConsumer,
Object message) |
void |
afterDelivery() |
boolean |
bindingQuery(String address) |
void |
browserFinished(ServerConsumer consumer) |
void |
cancel(Object brokerConsumer,
Object message,
boolean updateCounts) |
void |
close() |
void |
closed() |
void |
closeSender(Object brokerConsumer) |
void |
commitTX(org.apache.qpid.proton.amqp.Binary txid) |
void |
createDurableQueue(String address,
String queueName,
String filter) |
Object |
createSender(ProtonServerSenderContext protonSender,
String queue,
String filter,
boolean browserOnly) |
void |
createTemporaryQueue(String queueName) |
void |
createTemporaryQueue(String address,
String queueName,
String filter) |
void |
deleteQueue(String queueName) |
void |
disconnect(ServerConsumer consumer,
String queueName) |
long |
encodeMessage(Object message,
int deliveryCount,
org.apache.qpid.proton.codec.WritableBuffer buffer) |
String |
getPubSubPrefix() |
org.apache.activemq.artemis.core.transaction.Transaction |
getTransaction(org.apache.qpid.proton.amqp.Binary txid) |
boolean |
hasCredits(ServerConsumer consumer) |
void |
init(AMQPSessionContext protonSession,
SASLResult saslResult) |
boolean |
isWritable(ReadyListener callback) |
org.apache.qpid.proton.amqp.Binary |
newTransaction() |
void |
offerProducerCredit(String address,
int credits,
int threshold,
org.apache.qpid.proton.engine.Receiver receiver) |
void |
onFlowConsumer(Object consumer,
int credits,
boolean drain) |
QueueQueryResult |
queueQuery(String queueName,
boolean autoCreate) |
void |
resumeDelivery(Object consumer) |
void |
rollbackTX(org.apache.qpid.proton.amqp.Binary txid,
boolean lastMessageReceived) |
int |
sendLargeMessage(MessageReference ref,
ServerMessage message,
ServerConsumer consumer,
long bodySize,
int deliveryCount) |
int |
sendLargeMessageContinuation(ServerConsumer consumer,
byte[] body,
boolean continues,
boolean requiresResponse) |
int |
sendMessage(MessageReference ref,
ServerMessage message,
ServerConsumer consumer,
int deliveryCount) |
void |
sendProducerCreditsFailMessage(int credits,
SimpleString address) |
void |
sendProducerCreditsMessage(int credits,
SimpleString address) |
void |
serverSend(org.apache.activemq.artemis.core.transaction.Transaction transaction,
org.apache.qpid.proton.engine.Receiver receiver,
org.apache.qpid.proton.engine.Delivery delivery,
String address,
int messageFormat,
io.netty.buffer.ByteBuf messageEncoded) |
void |
start() |
void |
startSender(Object brokerConsumer) |
String |
tempQueueName() |
boolean |
updateDeliveryCountAfterCancel(ServerConsumer consumer,
MessageReference ref,
boolean failed) |
protected final IDGenerator consumerIDGenerator
public AMQPSessionCallback(AMQPConnectionCallback protonSPI, ProtonProtocolManager manager, AMQPConnectionContext connection, Connection transportConnection, Executor executor, org.apache.activemq.artemis.core.persistence.OperationContext operationContext)
public boolean isWritable(ReadyListener callback)
isWritable in interface SessionCallbackpublic void onFlowConsumer(Object consumer, int credits, boolean drain)
public void browserFinished(ServerConsumer consumer)
browserFinished in interface SessionCallbackpublic void init(AMQPSessionContext protonSession, SASLResult saslResult) throws Exception
Exceptionpublic void afterDelivery()
throws Exception
afterDelivery in interface SessionCallbackExceptionpublic void start()
public Object createSender(ProtonServerSenderContext protonSender, String queue, String filter, boolean browserOnly) throws Exception
Exceptionpublic void createTemporaryQueue(String queueName) throws Exception
Exceptionpublic void createTemporaryQueue(String address, String queueName, String filter) throws Exception
Exceptionpublic void createDurableQueue(String address, String queueName, String filter) throws Exception
Exceptionpublic QueueQueryResult queueQuery(String queueName, boolean autoCreate) throws Exception
Exceptionpublic long encodeMessage(Object message, int deliveryCount, org.apache.qpid.proton.codec.WritableBuffer buffer) throws Exception
Exceptionpublic String tempQueueName()
public void ack(org.apache.activemq.artemis.core.transaction.Transaction transaction, Object brokerConsumer, Object message) throws Exception
Exceptionpublic void cancel(Object brokerConsumer, Object message, boolean updateCounts) throws Exception
Exceptionpublic void resumeDelivery(Object consumer)
public void serverSend(org.apache.activemq.artemis.core.transaction.Transaction transaction, org.apache.qpid.proton.engine.Receiver receiver, org.apache.qpid.proton.engine.Delivery delivery, String address, int messageFormat, io.netty.buffer.ByteBuf messageEncoded) throws Exception
Exceptionpublic String getPubSubPrefix()
public void offerProducerCredit(String address, int credits, int threshold, org.apache.qpid.proton.engine.Receiver receiver)
public void sendProducerCreditsMessage(int credits,
SimpleString address)
sendProducerCreditsMessage in interface SessionCallbackpublic boolean updateDeliveryCountAfterCancel(ServerConsumer consumer, MessageReference ref, boolean failed)
updateDeliveryCountAfterCancel in interface SessionCallbackpublic void sendProducerCreditsFailMessage(int credits,
SimpleString address)
sendProducerCreditsFailMessage in interface SessionCallbackpublic int sendMessage(MessageReference ref, ServerMessage message, ServerConsumer consumer, int deliveryCount)
sendMessage in interface SessionCallbackpublic int sendLargeMessage(MessageReference ref, ServerMessage message, ServerConsumer consumer, long bodySize, int deliveryCount)
sendLargeMessage in interface SessionCallbackpublic int sendLargeMessageContinuation(ServerConsumer consumer, byte[] body, boolean continues, boolean requiresResponse)
sendLargeMessageContinuation in interface SessionCallbackpublic void closed()
closed in interface SessionCallbackpublic void disconnect(ServerConsumer consumer, String queueName)
disconnect in interface SessionCallbackpublic boolean hasCredits(ServerConsumer consumer)
hasCredits in interface SessionCallbackpublic org.apache.activemq.artemis.core.transaction.Transaction getTransaction(org.apache.qpid.proton.amqp.Binary txid) throws ActiveMQAMQPException
ActiveMQAMQPExceptionpublic org.apache.qpid.proton.amqp.Binary newTransaction()
public void commitTX(org.apache.qpid.proton.amqp.Binary txid)
throws Exception
ExceptionCopyright © 2017 The Apache Software Foundation. All Rights Reserved.