You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by fm...@apache.org on 2008/10/20 08:46:15 UTC

svn commit: r706129 - /incubator/sling/trunk/jcr/base/src/main/java/org/apache/sling/jcr/base/AbstractSlingRepository.java

Author: fmeschbe
Date: Sun Oct 19 23:46:14 2008
New Revision: 706129

URL: http://svn.apache.org/viewvc?rev=706129&view=rev
Log:
SLING-702 Catch RuntimeExceptions from Repository.login and forward
as RepositoryExceptions

Modified:
    incubator/sling/trunk/jcr/base/src/main/java/org/apache/sling/jcr/base/AbstractSlingRepository.java

Modified: incubator/sling/trunk/jcr/base/src/main/java/org/apache/sling/jcr/base/AbstractSlingRepository.java
URL: http://svn.apache.org/viewvc/incubator/sling/trunk/jcr/base/src/main/java/org/apache/sling/jcr/base/AbstractSlingRepository.java?rev=706129&r1=706128&r2=706129&view=diff
==============================================================================
--- incubator/sling/trunk/jcr/base/src/main/java/org/apache/sling/jcr/base/AbstractSlingRepository.java (original)
+++ incubator/sling/trunk/jcr/base/src/main/java/org/apache/sling/jcr/base/AbstractSlingRepository.java Sun Oct 19 23:46:14 2008
@@ -262,6 +262,11 @@
             // otherwise (any workspace) or if workspace creation fails
             // just forward the original exception
             throw nswe;
+            
+        } catch (RuntimeException re) {
+            // SLING-702: Jackrabbit throws IllegalStateException if the
+            // repository has already been shut down ...
+            throw new RepositoryException(re.getMessage(), re);
         }
     }