public class AMQSession extends Object implements SessionCallback
| Modifier and Type | Field and Description |
|---|---|
protected IDGenerator |
consumerIDGenerator |
| Constructor and Description |
|---|
AMQSession(org.apache.activemq.command.ConnectionInfo connInfo,
org.apache.activemq.command.SessionInfo sessInfo,
ActiveMQServer server,
OpenWireConnection connection,
ScheduledExecutorService scheduledPool) |
| Modifier and Type | Method and Description |
|---|---|
void |
afterDelivery() |
void |
browserFinished(ServerConsumer consumer) |
void |
close() |
void |
closed() |
List<AMQConsumer> |
createConsumer(org.apache.activemq.command.ConsumerInfo info,
SlowConsumerDetectionListener slowConsumerDetectionListener) |
void |
deliverMessage(org.apache.activemq.command.MessageDispatch dispatch) |
void |
disableSecurity() |
void |
disconnect(ServerConsumer consumerId,
String queueName) |
OpenWireConnection |
getConnection() |
org.apache.activemq.command.ConnectionInfo |
getConnectionInfo() |
OpenWireMessageConverter |
getConverter() |
ActiveMQServer |
getCoreServer() |
ServerSession |
getCoreSession() |
org.apache.activemq.wireformat.WireFormat |
getMarshaller() |
boolean |
hasCredits(ServerConsumer consumer) |
void |
initialize() |
boolean |
isClosed() |
boolean |
isWritable(ReadyListener callback) |
void |
send(org.apache.activemq.command.ProducerInfo producerInfo,
org.apache.activemq.command.Message messageSend,
boolean sendProducerAck) |
int |
sendLargeMessage(MessageReference reference,
ServerMessage message,
ServerConsumer consumerID,
long bodySize,
int deliveryCount) |
int |
sendLargeMessageContinuation(ServerConsumer consumerID,
byte[] body,
boolean continues,
boolean requiresResponse) |
int |
sendMessage(MessageReference reference,
ServerMessage message,
ServerConsumer consumer,
int deliveryCount) |
void |
sendProducerCreditsFailMessage(int credits,
org.apache.activemq.artemis.api.core.SimpleString address) |
void |
sendProducerCreditsMessage(int credits,
org.apache.activemq.artemis.api.core.SimpleString address) |
void |
start() |
boolean |
updateDeliveryCountAfterCancel(ServerConsumer consumer,
MessageReference ref,
boolean failed) |
protected final IDGenerator consumerIDGenerator
public AMQSession(org.apache.activemq.command.ConnectionInfo connInfo,
org.apache.activemq.command.SessionInfo sessInfo,
ActiveMQServer server,
OpenWireConnection connection,
ScheduledExecutorService scheduledPool)
public boolean isClosed()
public OpenWireMessageConverter getConverter()
public void initialize()
public boolean updateDeliveryCountAfterCancel(ServerConsumer consumer, MessageReference ref, boolean failed)
updateDeliveryCountAfterCancel in interface SessionCallbackpublic List<AMQConsumer> createConsumer(org.apache.activemq.command.ConsumerInfo info, SlowConsumerDetectionListener slowConsumerDetectionListener) throws Exception
Exceptionpublic void start()
public void afterDelivery()
throws Exception
afterDelivery in interface SessionCallbackExceptionpublic void browserFinished(ServerConsumer consumer)
browserFinished in interface SessionCallbackpublic boolean isWritable(ReadyListener callback)
isWritable in interface SessionCallbackpublic void sendProducerCreditsMessage(int credits,
org.apache.activemq.artemis.api.core.SimpleString address)
sendProducerCreditsMessage in interface SessionCallbackpublic void sendProducerCreditsFailMessage(int credits,
org.apache.activemq.artemis.api.core.SimpleString address)
sendProducerCreditsFailMessage in interface SessionCallbackpublic int sendMessage(MessageReference reference, ServerMessage message, ServerConsumer consumer, int deliveryCount)
sendMessage in interface SessionCallbackpublic int sendLargeMessage(MessageReference reference, ServerMessage message, ServerConsumer consumerID, long bodySize, int deliveryCount)
sendLargeMessage in interface SessionCallbackpublic int sendLargeMessageContinuation(ServerConsumer consumerID, byte[] body, boolean continues, boolean requiresResponse)
sendLargeMessageContinuation in interface SessionCallbackpublic void closed()
closed in interface SessionCallbackpublic boolean hasCredits(ServerConsumer consumer)
hasCredits in interface SessionCallbackpublic void disconnect(ServerConsumer consumerId, String queueName)
disconnect in interface SessionCallbackpublic void send(org.apache.activemq.command.ProducerInfo producerInfo,
org.apache.activemq.command.Message messageSend,
boolean sendProducerAck)
throws Exception
Exceptionpublic ServerSession getCoreSession()
public ActiveMQServer getCoreServer()
public org.apache.activemq.wireformat.WireFormat getMarshaller()
public org.apache.activemq.command.ConnectionInfo getConnectionInfo()
public void disableSecurity()
public void deliverMessage(org.apache.activemq.command.MessageDispatch dispatch)
public OpenWireConnection getConnection()
Copyright © 2023 The Apache Software Foundation. All Rights Reserved.