mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Fix SAIL-389 (SAIL-294): NodeDAO: single-valued, d:any properties don't handle increasing array values
- Incorrect translation of raw values back to Serializable for cache purposes - Addition of Savepoint around alf_node insert git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@21136 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -938,13 +938,16 @@ public abstract class AbstractNodeDAOImpl implements NodeDAO, BatchingDAO
|
||||
}
|
||||
|
||||
Long id = null;
|
||||
Savepoint savepoint = controlDAO.createSavepoint("newNodeImpl");
|
||||
try
|
||||
{
|
||||
// First try a straight insert and risk the constraint violation if the node exists
|
||||
id = insertNode(node);
|
||||
controlDAO.releaseSavepoint(savepoint);
|
||||
}
|
||||
catch (Throwable e)
|
||||
{
|
||||
controlDAO.rollbackToSavepoint(savepoint);
|
||||
// This is probably because there is an existing node. We can handle existing deleted nodes.
|
||||
NodeRef targetNodeRef = node.getNodeRef();
|
||||
NodeEntity deletedNode = selectNodeByNodeRef(targetNodeRef, true); // Only look for deleted nodes
|
||||
@@ -3071,7 +3074,7 @@ public abstract class AbstractNodeDAOImpl implements NodeDAO, BatchingDAO
|
||||
protected abstract Map<NodePropertyKey, NodePropertyValue> selectNodeProperties(Long nodeId);
|
||||
protected abstract Map<NodePropertyKey, NodePropertyValue> selectNodeProperties(Long nodeId, Set<Long> qnameIds);
|
||||
protected abstract int deleteNodeProperties(Long nodeId, Set<Long> qnameIds);
|
||||
protected abstract void deleteNodeProperties(Long nodeId, List<NodePropertyKey> propKeys);
|
||||
protected abstract int deleteNodeProperties(Long nodeId, List<NodePropertyKey> propKeys);
|
||||
protected abstract void insertNodeProperties(Long nodeId, Map<NodePropertyKey, NodePropertyValue> persistableProps);
|
||||
protected abstract Set<Long> selectNodeAspectIds(Long nodeId);
|
||||
protected abstract void insertNodeAspect(Long nodeId, Long qnameId);
|
||||
|
Reference in New Issue
Block a user