mirror of https://github.com/apache/activemq.git
JMS api object now implement a toString() that can be used to correlate back to log messages on the message broker. git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@358371 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
2040c9d75c
commit
22474cd541
|
@ -1542,4 +1542,8 @@ public class ActiveMQConnection implements Connection, TopicConnection, QueueCon
|
|||
public void setCopyMessageOnSend(boolean copyMessageOnSend) {
|
||||
this.copyMessageOnSend = copyMessageOnSend;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "ActiveMQConnection {id="+info.getConnectionId()+",clientId"+info.getClientId()+",started="+started.get()+"}";
|
||||
}
|
||||
}
|
|
@ -148,4 +148,8 @@ public class ActiveMQConnectionConsumer implements ConnectionConsumer, ActiveMQD
|
|||
connection.onAsyncException(e);
|
||||
}
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "ActiveMQConnectionConsumer { consumerId=" +consumerInfo.getConsumerId()+" }";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -227,4 +227,8 @@ public class ActiveMQInputStream extends InputStream implements ActiveMQDispatch
|
|||
unconsumedMessages.enqueue(md);
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "ActiveMQInputStream { consumerId="+info.getConsumerId()+", producerId=" +producerId+" }";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -727,5 +727,9 @@ public class ActiveMQMessageConsumer implements MessageAvailableConsumer, StatsC
|
|||
started.set(false);
|
||||
unconsumedMessages.stop();
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "ActiveMQMessageConsumer { consumerId=" +info.getConsumerId()+", started=" +started.get()+" }";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -500,4 +500,8 @@ public class ActiveMQMessageProducer implements MessageProducer, StatsCapable, C
|
|||
this.info = info;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "ActiveMQMessageProducer { consumerId=" +info.getProducerId()+" }";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -155,4 +155,8 @@ public class ActiveMQOutputStream extends OutputStream implements Disposable {
|
|||
connection.send(info.getDestination(), msg, id, deliveryMode, priority, timeToLive, !eosMessage);
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "ActiveMQOutputStream { producerId=" +info.getProducerId()+" }";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -242,4 +242,9 @@ public class ActiveMQQueueBrowser implements
|
|||
semaphore.notifyAll();
|
||||
}
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "ActiveMQQueueBrowser { consumerId=" +consumerId+" }";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -86,4 +86,5 @@ public class ActiveMQQueueReceiver extends ActiveMQMessageConsumer implements
|
|||
checkClosed();
|
||||
return (Queue) super.getDestination();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -1663,5 +1663,10 @@ public class ActiveMQSession implements Session, QueueSession, TopicSession, Sta
|
|||
public List getUnconsumedMessages() {
|
||||
return executor.getUnconsumedMessages();
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "ActiveMQSession {id="+info.getSessionId()+",started="+started.get()+"}";
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -142,5 +142,9 @@ public class PooledConnection implements TopicConnection, QueueConnection {
|
|||
protected ActiveMQSession createSession(SessionKey key) throws JMSException {
|
||||
return (ActiveMQSession) getConnection().createSession(key.isTransacted(), key.getAckMode());
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "PooledConnection { "+pool+" }";
|
||||
}
|
||||
|
||||
}
|
|
@ -126,4 +126,9 @@ public class PooledProducer implements MessageProducer {
|
|||
protected ActiveMQMessageProducer getMessageProducer() {
|
||||
return messageProducer;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "PooledProducer { "+messageProducer+" }";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -280,4 +280,7 @@ public class PooledSession implements TopicSession, QueueSession {
|
|||
return topicPublisher;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "PooledSession { "+session+" }";
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue