jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From resc...@apache.org
Subject svn commit: r1851063 - in /jackrabbit/branches/2.8: ./ jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/ItemInfoJSONHandler.java jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/RepositoryServiceImpl.java
Date Fri, 11 Jan 2019 15:34:56 GMT
Author: reschke
Date: Fri Jan 11 15:34:55 2019
New Revision: 1851063

URL: http://svn.apache.org/viewvc?rev=1851063&view=rev
Log:
JCR-4292: davex: preserve cause in exceptions and log affected URI (ported to 2.8)

Modified:
    jackrabbit/branches/2.8/   (props changed)
    jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/ItemInfoJSONHandler.java
    jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/RepositoryServiceImpl.java

Propchange: jackrabbit/branches/2.8/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Jan 11 15:34:55 2019
@@ -2,4 +2,4 @@
 /jackrabbit/branches/2.14:1813154
 /jackrabbit/branches/JCR-2272:1173165-1176545
 /jackrabbit/sandbox/JCR-2415-lucene-3.0:1060860-1064038
-/jackrabbit/trunk:1592881,1597717,1597799,1597806,1598035,1598058,1603769,1603934,1609712,1615997,1625561,1627529,1634584,1653275,1667787,1667795,1674859,1680757,1709811,1717599,1720093,1729382,1730696,1732436,1740814-1740815,1751279,1752165,1758600,1759607,1759782,1759865,1761679,1761909,1762422,1763558,1766398,1771078,1771741,1771939,1771999,1772049,1772343,1772444,1772457,1772530,1772544,1773579,1773591,1773745,1774443,1775657,1776384-1776385,1776407,1776413,1779166,1779460,1780208,1780335-1780336,1786325,1787043,1787381,1792100,1792105,1792113,1792193,1793315,1793323,1793327,1793332,1796980,1797209,1797917,1798586,1799429,1802977,1807234,1807244,1808752,1808754,1809149,1809329,1810108,1811667,1812994,1814831,1817097-1817098,1817100,1817201,1818586,1819269,1820133,1821597,1822863,1822947,1822950,1826230,1826647,1826940,1826964,1830540,1833374
+/jackrabbit/trunk:1592881,1597717,1597799,1597806,1598035,1598058,1603769,1603934,1609712,1615997,1625561,1627529,1634584,1653275,1667787,1667795,1674859,1680757,1709811,1717599,1720093,1729382,1730696,1732436,1740814-1740815,1751279,1752165,1758600,1759607,1759782,1759865,1761679,1761909,1762422,1763558,1766398,1771078,1771741,1771939,1771999,1772049,1772343,1772444,1772457,1772530,1772544,1773579,1773591,1773745,1774443,1775657,1776384-1776385,1776407,1776413,1779166,1779460,1780208,1780335-1780336,1786325,1787043,1787381,1792100,1792105,1792113,1792193,1793315,1793323,1793327,1793332,1796980,1797209,1797917,1798586,1799429,1802977,1807234,1807244,1808752,1808754,1809149,1809329,1810108,1811667,1812994,1814831,1817097-1817098,1817100,1817201,1818586,1819269,1820133,1821597,1822863,1822947,1822950,1826230,1826647,1826940,1826964,1830540,1830753,1833374

Modified: jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/ItemInfoJSONHandler.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/ItemInfoJSONHandler.java?rev=1851063&r1=1851062&r2=1851063&view=diff
==============================================================================
--- jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/ItemInfoJSONHandler.java
(original)
+++ jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/ItemInfoJSONHandler.java
Fri Jan 11 15:34:55 2019
@@ -105,7 +105,7 @@ class ItemInfoJsonHandler implements Jso
                 nodeInfos.push(nInfo);
                 propInfoLists.push(new ArrayList<PropertyInfoImpl>(8));
             } catch (RepositoryException e) {
-                throw new IOException(e.getMessage());
+                throw new IOException(e.getMessage(), e);
             }
         }
     }
@@ -132,7 +132,7 @@ class ItemInfoJsonHandler implements Jso
                 log.debug("Incomplete NodeInfo '"+ nInfo.getPath() + "' -> Only present
as ChildInfo with its parent.");
             }
         } catch (RepositoryException e) {
-            throw new IOException(e.getMessage());
+            throw new IOException(e.getMessage(), e);
         } finally {
             // reset all node-related handler state
             name = null;
@@ -163,7 +163,7 @@ class ItemInfoJsonHandler implements Jso
             propInfo.checkCompleted();
             getCurrentPropInfos().add(propInfo);
         } catch (RepositoryException e) {
-            throw new IOException(e.getMessage());
+            throw new IOException(e.getMessage(), e);
         } finally {
             // reset property-related handler state
             propertyType = PropertyType.UNDEFINED;
@@ -202,7 +202,7 @@ class ItemInfoJsonHandler implements Jso
                 index = Path.INDEX_DEFAULT;
             }
         } catch (RepositoryException e) {
-            throw new IOException(e.getMessage());
+            throw new IOException(e.getMessage(), e);
         }
     }
 
@@ -240,7 +240,7 @@ class ItemInfoJsonHandler implements Jso
             }
             value(v);
         } catch (RepositoryException e) {
-            throw new IOException(e.getMessage());
+            throw new IOException(e.getMessage(), e);
         }
     }
 
@@ -252,7 +252,7 @@ class ItemInfoJsonHandler implements Jso
         try {
             value(vFactory.create(value));
         } catch (RepositoryException e) {
-            throw new IOException(e.getMessage());
+            throw new IOException(e.getMessage(), e);
         }
     }
 
@@ -282,7 +282,7 @@ class ItemInfoJsonHandler implements Jso
                     int indx = (!multiValuedProperty) ? -1 : propValues.size();
                     value(vFactory.create(value, getValueURI(), indx));
                 } catch (RepositoryException e) {
-                    throw new IOException(e.getMessage());
+                    throw new IOException(e.getMessage(), e);
                 }
             }
             return;
@@ -290,7 +290,7 @@ class ItemInfoJsonHandler implements Jso
         try {
             value(vFactory.create(value));
         } catch (RepositoryException e) {
-            throw new IOException(e.getMessage());
+            throw new IOException(e.getMessage(), e);
         }
     }
 
@@ -302,7 +302,7 @@ class ItemInfoJsonHandler implements Jso
         try {
             value(vFactory.create(value));
         } catch (RepositoryException e) {
-            throw new IOException(e.getMessage());
+            throw new IOException(e.getMessage(), e);
         }
     }
 

Modified: jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/RepositoryServiceImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/RepositoryServiceImpl.java?rev=1851063&r1=1851062&r2=1851063&view=diff
==============================================================================
--- jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/RepositoryServiceImpl.java
(original)
+++ jackrabbit/branches/2.8/jackrabbit-spi2dav/src/main/java/org/apache/jackrabbit/spi2davex/RepositoryServiceImpl.java
Fri Jan 11 15:34:55 2019
@@ -375,8 +375,8 @@ public class RepositoryServiceImpl exten
             } catch (HttpException e) {
                 throw ExceptionConverter.generate(new DavException(method.getStatusCode(),
"Unable to retrieve NodeInfo for " + uri));
             } catch (IOException e) {
-                log.error("Internal error while retrieving NodeInfo.",e);
-                throw new RepositoryException(e.getMessage());
+                log.error("Internal error while retrieving NodeInfo for " + uri + ".", e);
+                throw new RepositoryException(e.getMessage(), e);
             } finally {
                 method.releaseConnection();
             }
@@ -433,8 +433,8 @@ public class RepositoryServiceImpl exten
                 return super.getPropertyInfo(sessionInfo, propertyId);
             }
         } catch (IOException e) {
-            log.error("Internal error while retrieving ItemInfo.",e);
-            throw new RepositoryException(e.getMessage());
+            log.error("Internal error while retrieving ItemInfo for " + uri + ".", e);
+            throw new RepositoryException(e.getMessage(), e);
         } catch (DavException e) {
             throw ExceptionConverter.generate(e);
         } finally {



Mime
View raw message