Renamed to EventHandler and added 'info, debug, warning and error'

This commit is contained in:
Jonas Bonér 2011-03-02 18:19:17 +01:00
parent a41fd15228
commit 793ad9ac03
16 changed files with 132 additions and 123 deletions

View file

@ -10,7 +10,7 @@ import atomic.{AtomicLong, AtomicInteger}
import ThreadPoolExecutor.CallerRunsPolicy
import akka.util.Duration
import akka.actor.{ErrorHandler, ErrorHandlerEvent}
import akka.actor.{EventHandler}
object ThreadPoolConfig {
type Bounds = Int
@ -208,10 +208,10 @@ class BoundedExecutorDecorator(val executor: ExecutorService, bound: Int) extend
})
} catch {
case e: RejectedExecutionException =>
ErrorHandler notifyListeners ErrorHandlerEvent(e, this)
EventHandler notifyListeners EventHandler.Warning(e, this)
semaphore.release
case e =>
ErrorHandler notifyListeners ErrorHandlerEvent(e, this)
case e: Throwable =>
EventHandler notifyListeners EventHandler.Error(e, this)
throw e
}
}