You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@excalibur.apache.org by le...@apache.org on 2005/09/05 08:45:18 UTC

svn commit: r278681 - /excalibur/trunk/containerkit/instrument/mgr-impl/src/java/org/apache/excalibur/instrument/manager/impl/DefaultInstrumentManagerImpl.java

Author: leif
Date: Sun Sep  4 23:45:02 2005
New Revision: 278681

URL: http://svn.apache.org/viewcvs?rev=278681&view=rev
Log:
Improve the way errors are reported to the user in the event of a corrupted or unread/writable instrument sample file.

Modified:
    excalibur/trunk/containerkit/instrument/mgr-impl/src/java/org/apache/excalibur/instrument/manager/impl/DefaultInstrumentManagerImpl.java

Modified: excalibur/trunk/containerkit/instrument/mgr-impl/src/java/org/apache/excalibur/instrument/manager/impl/DefaultInstrumentManagerImpl.java
URL: http://svn.apache.org/viewcvs/excalibur/trunk/containerkit/instrument/mgr-impl/src/java/org/apache/excalibur/instrument/manager/impl/DefaultInstrumentManagerImpl.java?rev=278681&r1=278680&r2=278681&view=diff
==============================================================================
--- excalibur/trunk/containerkit/instrument/mgr-impl/src/java/org/apache/excalibur/instrument/manager/impl/DefaultInstrumentManagerImpl.java (original)
+++ excalibur/trunk/containerkit/instrument/mgr-impl/src/java/org/apache/excalibur/instrument/manager/impl/DefaultInstrumentManagerImpl.java Sun Sep  4 23:45:02 2005
@@ -298,10 +298,18 @@
                     }
                     catch( Exception e )
                     {
-                        getLogger().error(
-                            "Unable to load the instrument manager state.  The configuration " +
-                            "may have been corruptped.  A backup may have been made in the same " +
-                            "directory when it was saved.", e );
+                        String msg = "Unable to load the instrument manager state.  The "
+                            + "configuration may have been corrupted.  A backup may have been "
+                            + "made in the same directory when it was saved.";
+                        
+                        if ( getLogger().isDebugEnabled() )
+                        {
+                            getLogger().error( msg, e );
+                        }
+                        else
+                        {
+                            getLogger().error( msg + " : " + e.toString() );
+                        }
                     }
                 }
             }
@@ -1251,7 +1259,15 @@
         }
         catch ( Exception e )
         {
-            getLogger().warn( "Unable to save the Instrument Manager state", e );
+            String msg = "Unable to save the Instrument Manager state";
+            if ( getLogger().isDebugEnabled() )
+            {
+                getLogger().warn( msg, e );
+            }
+            else
+            {
+                getLogger().warn( msg + " : " + e.toString() );
+            }
         }
         
         m_stateSavesInstrument.increment();



---------------------------------------------------------------------
To unsubscribe, e-mail: scm-unsubscribe@excalibur.apache.org
For additional commands, e-mail: scm-help@excalibur.apache.org