Index: oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentRootBuilder.java =================================================================== --- oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentRootBuilder.java (revision 1708366) +++ oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentRootBuilder.java (working copy) @@ -29,6 +29,8 @@ import org.apache.jackrabbit.oak.spi.commit.CommitInfo; import org.apache.jackrabbit.oak.spi.state.ConflictAnnotatingRebaseDiff; import org.apache.jackrabbit.oak.spi.state.NodeState; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; /** * This implementation tracks the number of pending changes and purges them to @@ -42,6 +44,9 @@ */ static final int UPDATE_LIMIT = Integer.getInteger("update.limit", 10000); + private static final Logger LOG = LoggerFactory.getLogger(DocumentRootBuilder.class); + + /** * The underlying store */ @@ -66,6 +71,13 @@ */ private int updates; + + /** + * Indicates when the next warning about persisted nodes is logged + */ + private int updateWarnLevel; + + DocumentRootBuilder(@Nonnull DocumentNodeState base, @Nonnull DocumentNodeStore store) { super(checkNotNull(base)); @@ -72,6 +84,7 @@ this.store = checkNotNull(store); this.base = base; this.branch = store.createBranch(base); + this.updateWarnLevel = UPDATE_LIMIT; } //--------------------------------------------------< MemoryNodeBuilder >--- @@ -97,6 +110,10 @@ protected void updated() { if (++updates > UPDATE_LIMIT) { purge(); + if (updates > updateWarnLevel) { + LOG.warn("Updated more than {} nodes in transient space, overflowing to persistence", updateWarnLevel); + updateWarnLevel = 2 * updateWarnLevel; + } } } Index: oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/VersionGarbageCollector.java =================================================================== --- oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/VersionGarbageCollector.java (revision 1708366) +++ oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/VersionGarbageCollector.java (working copy) @@ -1,4 +1,4 @@ -/* +* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information