jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ste...@apache.org
Subject svn commit: r170561 - /incubator/jackrabbit/trunk/src/java/org/apache/jackrabbit/core/ItemManager.java
Date Tue, 17 May 2005 10:36:16 GMT
Author: stefan
Date: Tue May 17 03:36:13 2005
New Revision: 170561

URL: http://svn.apache.org/viewcvs?rev=170561&view=rev
Log:
cleaned up exception handling in ItemManager.createItemInstance & getItemState

Modified:
    incubator/jackrabbit/trunk/src/java/org/apache/jackrabbit/core/ItemManager.java

Modified: incubator/jackrabbit/trunk/src/java/org/apache/jackrabbit/core/ItemManager.java
URL: http://svn.apache.org/viewcvs/incubator/jackrabbit/trunk/src/java/org/apache/jackrabbit/core/ItemManager.java?rev=170561&r1=170560&r2=170561&view=diff
==============================================================================
--- incubator/jackrabbit/trunk/src/java/org/apache/jackrabbit/core/ItemManager.java (original)
+++ incubator/jackrabbit/trunk/src/java/org/apache/jackrabbit/core/ItemManager.java Tue May
17 03:36:13 2005
@@ -238,8 +238,8 @@
             throw new ItemNotFoundException(msg);
         } catch (ItemStateException ise) {
             String msg = "failed to retrieve item state of " + id;
-            log.debug(msg);
-            throw new RepositoryException(msg);
+            log.error(msg);
+            throw new RepositoryException(msg, ise);
         }
     }
 
@@ -507,18 +507,19 @@
     }
 
     //-------------------------------------------------< item factory methods >
-    private ItemImpl createItemInstance(ItemId id) throws ItemNotFoundException, RepositoryException
{
+    private ItemImpl createItemInstance(ItemId id)
+            throws ItemNotFoundException, RepositoryException {
         // create instance of item using its state object
         ItemImpl item;
         ItemState state;
         try {
             state = itemStateProvider.getItemState(id);
-        } catch (NoSuchItemStateException ise) {
+        } catch (NoSuchItemStateException nsise) {
             throw new ItemNotFoundException(id.toString());
         } catch (ItemStateException ise) {
             String msg = "failed to retrieve item state of item " + id;
-            log.debug(msg);
-            throw new RepositoryException(msg);
+            log.error(msg, ise);
+            throw new RepositoryException(msg, ise);
         }
 
         if (state.isNode()) {



Mime
View raw message