Merged HEAD-BUG-FIX (4.3/Cloud) to HEAD (4.3/Cloud)

60624: Failures in post-commit writes of NewCacheBuckets and UpdateCacheBuckets are logged in more details (MNT-10486)


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@62354 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Alan Davis
2014-02-12 14:30:50 +00:00
parent a67d74a6da
commit c7ed0857ae

View File

@@ -937,9 +937,26 @@ public class TransactionalCache<K extends Serializable, V extends Object>
{
Serializable key = entry.getKey();
CacheBucket<V> bucket = entry.getValue();
bucket.doPostCommit(
sharedCache,
key, this.isMutable, this.allowEqualsChecks, txnData.isReadOnly);
try
{
bucket.doPostCommit(
sharedCache,
key, this.isMutable, this.allowEqualsChecks, txnData.isReadOnly);
}
catch (Exception e)
{
// MNT-10486: NPE in NodeEntity during post-commit write through to shared cache
// This try-catch is diagnostic in nature. We need to know the names of the caches
// and details of the values involved.
// The causal exception will be rethrown.
throw new AlfrescoRuntimeException(
"CacheBucket postCommit transfer to shared cache failed: \n" +
" Cache: " + sharedCache + "\n" +
" Key: " + key + "\n" +
" New Value: " + bucket.getValue() + "\n" +
" Cash Value: " + sharedCache.get(key),
e);
}
}
if (isDebugEnabled)
{