activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chir...@apache.org
Subject svn commit: r1066199 - in /activemq/activemq-apollo/trunk: apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/ apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/ apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/br...
Date Tue, 01 Feb 2011 20:50:59 GMT
Author: chirino
Date: Tue Feb  1 20:50:58 2011
New Revision: 1066199

URL: http://svn.apache.org/viewvc?rev=1066199&view=rev
Log:
Removed the DispatchLogging trait.

Modified:
    activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBClient.scala
    activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBStore.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Queue.scala
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Router.scala
    activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBClient.scala
    activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBStore.scala
    activemq/activemq-apollo/trunk/apollo-jdbm2/src/main/scala/org/apache/activemq/apollo/broker/store/jdbm2/JDBM2Store.scala
    activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompCodec.scala
    activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
    activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Logging.scala

Modified: activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBClient.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBClient.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBClient.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBClient.scala
Tue Feb  1 20:50:58 2011
@@ -33,11 +33,11 @@ object BDBClient extends Log
  *
  * @author <a href="http://hiramchirino.com">Hiram Chirino</a>
  */
-class BDBClient(store: BDBStore) extends DispatchLogging {
+class BDBClient(store: BDBStore) {
 
   import HelperTrait._
 
-  override def log: Log = BDBClient
+  import BDBClient._
 
   def dispatchQueue = store.dispatch_queue
 

Modified: activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBStore.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBStore.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBStore.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-bdb/src/main/scala/org/apache/activemq/apollo/broker/store/bdb/BDBStore.scala
Tue Feb  1 20:50:58 2011
@@ -60,12 +60,10 @@ object BDBStore extends Log {
 /**
  * @author <a href="http://hiramchirino.com">Hiram Chirino</a>
  */
-class BDBStore extends DelayingStoreSupport with DispatchLogging {
+class BDBStore extends DelayingStoreSupport {
 
   import BDBStore._
 
-  override def log: Log = BDBStore
-
   var next_queue_key = new AtomicLong(1)
   var next_msg_key = new AtomicLong(1)
 

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Queue.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Queue.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Queue.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Queue.scala
Tue Feb  1 20:50:58 2011
@@ -637,12 +637,13 @@ class Queue(val router: LocalRouter, val
 
 }
 
-object QueueEntry extends Sizer[QueueEntry] {
+object QueueEntry extends Sizer[QueueEntry] with Log {
   def size(value: QueueEntry): Int = value.size
 }
 
-class QueueEntry(val queue:Queue, val seq:Long) extends LinkedNode[QueueEntry] with Comparable[QueueEntry]
with Runnable with DispatchLogging {
-  override protected def log = Queue
+class QueueEntry(val queue:Queue, val seq:Long) extends LinkedNode[QueueEntry] with Comparable[QueueEntry]
with Runnable {
+  import QueueEntry._
+
   // Subscriptions waiting to dispatch this entry.
   var parked:List[Subscription] = Nil
 
@@ -1337,14 +1338,16 @@ class QueueEntry(val queue:Queue, val se
 
 }
 
+object Subscription extends Log
+
 /**
  * Interfaces a DispatchConsumer with a Queue.  Tracks current position of the consumer
  * on the queue, and the delivery rate so that slow consumers can be detected.  It also
  * tracks the entries which the consumer has acquired.
  *
  */
-class Subscription(val queue:Queue, val consumer:DeliveryConsumer) extends DeliveryProducer
with DispatchLogging {
-  override protected def log = Queue
+class Subscription(val queue:Queue, val consumer:DeliveryConsumer) extends DeliveryProducer
{
+  import Subscription._
 
   def dispatch_queue = queue.dispatch_queue
 

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Router.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Router.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Router.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Router.scala
Tue Feb  1 20:50:58 2011
@@ -67,7 +67,6 @@ object DeliveryProducerRoute extends Log
 /**
  * @author <a href="http://hiramchirino.com">Hiram Chirino</a>
  */
-// case class DeliveryProducerRoute(val router:Router, val destination:DestinationDTO, val
path:Path, val producer:DeliveryProducer, val security:SecurityContext) extends BaseRetained
with Route with Sink[Delivery] with DispatchLogging {
 abstract class DeliveryProducerRoute(val router:Router) extends BaseRetained with BindableDeliveryProducer
with Sink[Delivery] {
 
   import DeliveryProducerRoute._

Modified: activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBClient.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBClient.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBClient.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBClient.scala
Tue Feb  1 20:50:58 2011
@@ -54,12 +54,10 @@ object HawtDBClient extends Log {
  *
  * @author <a href="http://hiramchirino.com">Hiram Chirino</a>
  */
-class HawtDBClient(hawtDBStore: HawtDBStore) extends DispatchLogging {
+class HawtDBClient(hawtDBStore: HawtDBStore) {
   import HawtDBClient._
   import Helpers._
 
-  override def log: Log = HawtDBClient
-
   def dispatchQueue = hawtDBStore.dispatch_queue
 
 

Modified: activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBStore.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBStore.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBStore.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-hawtdb/src/main/scala/org/apache/activemq/apollo/broker/store/hawtdb/HawtDBStore.scala
Tue Feb  1 20:50:58 2011
@@ -60,10 +60,9 @@ object HawtDBStore extends Log {
 /**
  * @author <a href="http://hiramchirino.com">Hiram Chirino</a>
  */
-class HawtDBStore extends DelayingStoreSupport with DispatchLogging {
+class HawtDBStore extends DelayingStoreSupport {
 
   import HawtDBStore._
-  override protected def log = HawtDBStore
 
   var next_queue_key = new AtomicLong(1)
   var next_msg_key = new AtomicLong(1)

Modified: activemq/activemq-apollo/trunk/apollo-jdbm2/src/main/scala/org/apache/activemq/apollo/broker/store/jdbm2/JDBM2Store.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-jdbm2/src/main/scala/org/apache/activemq/apollo/broker/store/jdbm2/JDBM2Store.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-jdbm2/src/main/scala/org/apache/activemq/apollo/broker/store/jdbm2/JDBM2Store.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-jdbm2/src/main/scala/org/apache/activemq/apollo/broker/store/jdbm2/JDBM2Store.scala
Tue Feb  1 20:50:58 2011
@@ -61,12 +61,10 @@ object JDBM2Store extends Log {
 /**
  * @author <a href="http://hiramchirino.com">Hiram Chirino</a>
  */
-class JDBM2Store extends DelayingStoreSupport with DispatchLogging {
+class JDBM2Store extends DelayingStoreSupport {
 
   import JDBM2Store._
 
-  override def log: Log = JDBM2Store
-
   var next_queue_key = new AtomicLong(1)
   var next_msg_key = new AtomicLong(1)
 

Modified: activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompCodec.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompCodec.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompCodec.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompCodec.scala
Tue Feb  1 20:50:58 2011
@@ -152,10 +152,9 @@ object StompCodec extends Log {
 
 }
 
-class StompCodec extends ProtocolCodec with DispatchLogging {
+class StompCodec extends ProtocolCodec {
 
   import StompCodec._
-  override protected def log: Log = StompCodec
 
   var zero_copy_buffer_allocator:ZeroCopyBufferAllocator = null
 

Modified: activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
Tue Feb  1 20:50:58 2011
@@ -61,7 +61,8 @@ import StompProtocolHandler._
 /**
  * @author <a href="http://hiramchirino.com">Hiram Chirino</a>
  */
-class StompProtocolHandler extends ProtocolHandler with DispatchLogging {
+class StompProtocolHandler extends ProtocolHandler {
+  import StompProtocolHandler._
 
   def protocol = "stomp"
 
@@ -100,8 +101,6 @@ class StompProtocolHandler extends Proto
     rc.toBuffer.ascii
   }
 
-  override protected def log = StompProtocolHandler
-
   protected def dispatchQueue:DispatchQueue = connection.dispatch_queue
 
   trait AckHandler {

Modified: activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Logging.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Logging.scala?rev=1066199&r1=1066198&r2=1066199&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Logging.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-util/src/main/scala/org/apache/activemq/apollo/util/Logging.scala
Tue Feb  1 20:50:58 2011
@@ -42,15 +42,15 @@ trait Log {
     if( e!=null ) {
       val stack_ref = if( log.isDebugEnabled ) {
         val id = next_exception_id
-        MDC.put("stack reference", id.toString);
+        MDC.put("stackref", id.toString);
         Some(id)
       } else {
         None
       }
       func
       stack_ref.foreach { id=>
-        log.debug("stack trace: "+id, e)
-        MDC.remove("stack reference")
+        log.debug(e.toString, e)
+        MDC.remove("stackref")
       }
     } else {
       func
@@ -206,9 +206,3 @@ trait Logging {
   protected def trace(e: Throwable)= log.trace(e)
 
 }
-
-/**
- * @author <a href="http://hiramchirino.com">Hiram Chirino</a>
- */
-trait DispatchLogging extends Logging {
-}



Mime
View raw message