public class ConnectionStateTracker extends CommandVisitorAdapter
Modifier and Type | Field and Description |
---|---|
protected ConcurrentMap<ConnectionId,ConnectionState> |
connectionStates |
Constructor and Description |
---|
ConnectionStateTracker() |
processBrokerInfo, processConnectionControl, processConnectionError, processConsumerControl, processControlCommand, processFlush, processForgetTransaction, processKeepAlive, processMessageAck, processMessageDispatch, processMessageDispatchNotification, processProducerAck, processRecoverTransactions, processRemoveSubscription, processShutdown, processWireFormat
protected final ConcurrentMap<ConnectionId,ConnectionState> connectionStates
public ConnectionStateTracker()
public Tracked track(Command command) throws IOException
command
- The command that is to be tracked by this tracker.IOException
- if an error occurs during setup of the tracking operation.public void trackBack(Command command)
command
- The command that was previously provided to the track method.public void restore(Transport transport) throws IOException
IOException
protected void restoreSessions(Transport transport, ConnectionState connectionState) throws IOException
transport
- connectionState
- IOException
protected void restoreConsumers(Transport transport, SessionState sessionState) throws IOException
transport
- sessionState
- IOException
protected void restoreProducers(Transport transport, SessionState sessionState) throws IOException
transport
- sessionState
- IOException
protected void restoreTempDestinations(Transport transport, ConnectionState connectionState) throws IOException
transport
- connectionState
- IOException
public Response processAddDestination(DestinationInfo info)
processAddDestination
in interface CommandVisitor
processAddDestination
in class CommandVisitorAdapter
public Response processRemoveDestination(DestinationInfo info)
processRemoveDestination
in interface CommandVisitor
processRemoveDestination
in class CommandVisitorAdapter
public Response processAddProducer(ProducerInfo info)
processAddProducer
in interface CommandVisitor
processAddProducer
in class CommandVisitorAdapter
public Response processRemoveProducer(ProducerId id)
processRemoveProducer
in interface CommandVisitor
processRemoveProducer
in class CommandVisitorAdapter
public Response processAddConsumer(ConsumerInfo info)
processAddConsumer
in interface CommandVisitor
processAddConsumer
in class CommandVisitorAdapter
public Response processRemoveConsumer(ConsumerId id, long lastDeliveredSequenceId)
processRemoveConsumer
in interface CommandVisitor
processRemoveConsumer
in class CommandVisitorAdapter
public Response processAddSession(SessionInfo info)
processAddSession
in interface CommandVisitor
processAddSession
in class CommandVisitorAdapter
public Response processRemoveSession(SessionId id, long lastDeliveredSequenceId)
processRemoveSession
in interface CommandVisitor
processRemoveSession
in class CommandVisitorAdapter
public Response processAddConnection(ConnectionInfo info)
processAddConnection
in interface CommandVisitor
processAddConnection
in class CommandVisitorAdapter
public Response processRemoveConnection(ConnectionId id, long lastDeliveredSequenceId) throws Exception
processRemoveConnection
in interface CommandVisitor
processRemoveConnection
in class CommandVisitorAdapter
Exception
public Response processMessage(Message send) throws Exception
processMessage
in interface CommandVisitor
processMessage
in class CommandVisitorAdapter
Exception
public Response processBeginTransaction(TransactionInfo info)
processBeginTransaction
in interface CommandVisitor
processBeginTransaction
in class CommandVisitorAdapter
public Response processPrepareTransaction(TransactionInfo info) throws Exception
processPrepareTransaction
in interface CommandVisitor
processPrepareTransaction
in class CommandVisitorAdapter
Exception
public Response processCommitTransactionOnePhase(TransactionInfo info) throws Exception
processCommitTransactionOnePhase
in interface CommandVisitor
processCommitTransactionOnePhase
in class CommandVisitorAdapter
Exception
public Response processCommitTransactionTwoPhase(TransactionInfo info) throws Exception
processCommitTransactionTwoPhase
in interface CommandVisitor
processCommitTransactionTwoPhase
in class CommandVisitorAdapter
Exception
public Response processRollbackTransaction(TransactionInfo info) throws Exception
processRollbackTransaction
in interface CommandVisitor
processRollbackTransaction
in class CommandVisitorAdapter
Exception
public Response processEndTransaction(TransactionInfo info) throws Exception
processEndTransaction
in interface CommandVisitor
processEndTransaction
in class CommandVisitorAdapter
Exception
public Response processMessagePull(MessagePull pull) throws Exception
processMessagePull
in interface CommandVisitor
processMessagePull
in class CommandVisitorAdapter
Exception
public boolean isRestoreConsumers()
public void setRestoreConsumers(boolean restoreConsumers)
public boolean isRestoreProducers()
public void setRestoreProducers(boolean restoreProducers)
public boolean isRestoreSessions()
public void setRestoreSessions(boolean restoreSessions)
public boolean isTrackTransactions()
public void setTrackTransactions(boolean trackTransactions)
public boolean isTrackTransactionProducers()
public void setTrackTransactionProducers(boolean trackTransactionProducers)
public boolean isRestoreTransaction()
public void setRestoreTransaction(boolean restoreTransaction)
public boolean isTrackMessages()
public void setTrackMessages(boolean trackMessages)
public int getMaxCacheSize()
public void setMaxCacheSize(int maxCacheSize)
public long getCurrentCacheSize()
public void connectionInterruptProcessingComplete(Transport transport, ConnectionId connectionId)
public void transportInterrupted(ConnectionId connectionId)
Copyright © 2005–2016 FuseSource, Corp.. All rights reserved.