Browse files

ostrich more exceptions

  • Loading branch information...
1 parent b1fd3c4 commit 836bfd3006d47ec87946d98903ec15201f18b324 @fizx fizx committed Oct 18, 2010
Showing with 5 additions and 1 deletion.
  1. +5 −1 src/main/scala/com/twitter/flockdb/EdgesService.scala
View
6 src/main/scala/com/twitter/flockdb/EdgesService.scala
@@ -116,10 +116,14 @@ class EdgesService(val nameServer: NameServer[shards.Shard],
try {
block
} catch {
- case e: FlockException => throw(e)
+ case e: FlockException => {
+ Stats.incr(e.getClass.getName)
+ throw(e)
+ }
case e: com.twitter.gizzard.shards.ShardTimeoutException => countAndRethrow(e)
case e: com.twitter.gizzard.shards.ShardDatabaseTimeoutException => countAndRethrow(e)
case e: Throwable => {
+ Stats.incr("unknown-exceptions")
log.error(e, "Unhandled error in EdgesService")
throw(new FlockException(e.getMessage))
}

0 comments on commit 836bfd3

Please sign in to comment.