[ALF-22056] onCopyCompleteBehaviour not called in order of copy-action Created: 10-Jan-19  Updated: 16-Oct-19  Resolved: 19-Feb-19

Status: Closed
Project: Alfresco
Component/s: Repository
Affects Version/s: Community Edition Next
Fix Version/s: ACS 201910-EA
Security Level: external (External user)

Type: Bug Priority: Major
Reporter: Jens Kluttig Assignee: Closed Issues
Resolution: Fixed Votes: 0
Labels: triaged
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Shadow
shadowed by REPO-4147 6.2: ALF-22056: onCopyCompleteBehavio... Done
Triage: MNT

 Description   

If a folder with documents is copied then the onCopyComplete-Policy is not called in the exact order of the childs.

Scenario:

In our project we have a domain specific indentifier for children of a folder, which is added via a behaviour.

Expectation:

If a folder is copied, then this identifier is the same as in the copy-source.

Observation:

The children are copied in the right order, but the identifier is added randomly.

Proposed solution:

I debugged this and found out that the problem is the implementation of an map in the CopyServiceImpl.copy method. This method holds all copied nodes on which later the onCopyComplete-Policy is executed. But this Map is a HashMap, which order is defined by the hashValue of its entries.

I thought this might be the best way to contribute my first code-changes via a pull-request.

https://github.com/Alfresco/alfresco-repository/pull/319

 

 

 


Generated at Fri Sep 25 18:49:47 BST 2020 using Jira 7.13.15#713015-sha1:7c5ddd2c3e1709974ae9c48c17df8edd3919fe2c.