cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r758994 - /incubator/cassandra/trunk/src/org/apache/cassandra/service/CassandraServer.java
Date Fri, 27 Mar 2009 02:43:58 GMT
Author: jbellis
Date: Fri Mar 27 02:43:57 2009
New Revision: 758994

URL: http://svn.apache.org/viewvc?rev=758994&view=rev
Log:
add defaultuncaughtexceptionhandler that logs runtime errors

Modified:
    incubator/cassandra/trunk/src/org/apache/cassandra/service/CassandraServer.java

Modified: incubator/cassandra/trunk/src/org/apache/cassandra/service/CassandraServer.java
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/src/org/apache/cassandra/service/CassandraServer.java?rev=758994&r1=758993&r2=758994&view=diff
==============================================================================
--- incubator/cassandra/trunk/src/org/apache/cassandra/service/CassandraServer.java (original)
+++ incubator/cassandra/trunk/src/org/apache/cassandra/service/CassandraServer.java Fri Mar
27 02:43:57 2009
@@ -855,6 +855,14 @@
 	{
 		int port = 9160;		
 
+        Thread.setDefaultUncaughtExceptionHandler(new Thread.UncaughtExceptionHandler()
+        {
+            public void uncaughtException(Thread t, Throwable e)
+            {
+                logger_.error("Fatal exception in thread " + t, e);
+            }
+        });
+
 		try
 		{
 			CassandraServer peerStorageServer = new CassandraServer();



Mime
View raw message