This allow spring 2.0 to work with xbean-2.5

git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@427613 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Hiram R. Chirino 2006-08-01 15:30:46 +00:00
parent 6b03bd3f9b
commit 4c1cc956cc
3 changed files with 6 additions and 19 deletions

View File

@ -34,13 +34,10 @@ import org.apache.commons.logging.LogFactory;
public class LoggingBrokerPlugin extends BrokerPluginSupport {
private Log log = LogFactory.getLog(LoggingBrokerPlugin.class);
private Log sendLog;
private Log ackLog;
private Log sendLog = LogFactory.getLog(LoggingBrokerPlugin.class.getName()+".Send");
private Log ackLog = LogFactory.getLog(LoggingBrokerPlugin.class.getName()+".Ack");
public void send(ConnectionContext context, Message messageSend) throws Exception {
if (sendLog == null) {
sendLog = createLog("Send");
}
if (sendLog.isInfoEnabled()) {
sendLog.info("Sending: " + messageSend);
}
@ -48,9 +45,6 @@ public class LoggingBrokerPlugin extends BrokerPluginSupport {
}
public void acknowledge(ConnectionContext context, MessageAck ack) throws Exception {
if (ackLog == null) {
ackLog = createLog("Ack");
}
if (ackLog.isInfoEnabled()) {
ackLog.info("Acknowledge: " + ack);
}
@ -83,14 +77,4 @@ public class LoggingBrokerPlugin extends BrokerPluginSupport {
this.sendLog = sendLog;
}
// Implementation methods
// -------------------------------------------------------------------------
/**
* Lazily creates a new child log
*/
protected Log createLog(String name) {
return LogFactory.getLog(log.toString() + "." + name);
}
}

View File

@ -0,0 +1 @@
http\://activemq.org/config/1.0=org.apache.xbean.spring.context.v2.XBeanNamespaceHandler

View File

@ -131,6 +131,8 @@
<module>activemq-web-console</module>
<module>activemq-optional</module>
<module>maven-bundle-plugin</module>
<module>maven-gram-plugin</module>
<module>activemq-openwire-generator</module>
<module>assembly</module>
<module>activeio</module>
<!--module>activemq-systest</module -->
@ -943,6 +945,6 @@
<xmlbeans-version>2.0.0-beta1</xmlbeans-version>
<xmlpull-version>1.1.3.4d_b4_min</xmlpull-version>
<xstream-version>1.1.2</xstream-version>
<xbean-version>2.5</xbean-version>
<xbean-version>2.6-SNAPSHOT</xbean-version>
</properties>
</project>