jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From resc...@apache.org
Subject svn commit: r1196563 - in /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core: ItemSaveOperation.java state/ChangeLog.java state/LocalItemStateManager.java state/SessionItemStateManager.java
Date Wed, 02 Nov 2011 13:08:45 GMT
Author: reschke
Date: Wed Nov  2 13:08:44 2011
New Revision: 1196563

URL: http://svn.apache.org/viewvc?rev=1196563&view=rev
Log:
JCR-3099: add asserts so we can collect additional information when the problem recurs

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/ItemSaveOperation.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/ChangeLog.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/LocalItemStateManager.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SessionItemStateManager.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/ItemSaveOperation.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/ItemSaveOperation.java?rev=1196563&r1=1196562&r2=1196563&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/ItemSaveOperation.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/ItemSaveOperation.java
Wed Nov  2 13:08:44 2011
@@ -718,6 +718,7 @@ class ItemSaveOperation implements Sessi
             // remove persistent state
             // this will indirectly (through stateDestroyed listener method)
             // permanently invalidate all Item instances wrapping it
+            assert persistentState != null;
             sism.destroy(persistentState);
         }
     }

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/ChangeLog.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/ChangeLog.java?rev=1196563&r1=1196562&r2=1196563&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/ChangeLog.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/ChangeLog.java
Wed Nov  2 13:08:44 2011
@@ -101,6 +101,7 @@ public class ChangeLog {
      * @param state state that has been deleted
      */
     public void deleted(ItemState state) {
+        assert state != null;
         if (addedStates.remove(state.getId()) == null) {
             state.disconnect();
             modifiedStates.remove(state.getId());

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/LocalItemStateManager.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/LocalItemStateManager.java?rev=1196563&r1=1196562&r2=1196563&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/LocalItemStateManager.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/LocalItemStateManager.java
Wed Nov  2 13:08:44 2011
@@ -342,6 +342,7 @@ public class LocalItemStateManager
      * {@inheritDoc}
      */
     public void destroy(ItemState state) throws IllegalStateException {
+        assert state != null;
         if (!editMode) {
             throw new IllegalStateException("Not in edit mode");
         }

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SessionItemStateManager.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SessionItemStateManager.java?rev=1196563&r1=1196562&r2=1196563&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SessionItemStateManager.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SessionItemStateManager.java
Wed Nov  2 13:08:44 2011
@@ -255,6 +255,7 @@ public class SessionItemStateManager
      * {@inheritDoc}
      */
     public void destroy(ItemState state) throws IllegalStateException {
+        assert state != null;
         stateMgr.destroy(state);
     }
 



Mime
View raw message