Defect #3039
closedSynchronization from system - multivalued EAV attribute is not deleted when the new value is an empty List
100%
Description
Tested on 11.2.1.
We have a multivalued EAV attribute filled by the synchronization from the system. We use a transformation script, which returns ArrayList of values. This is filled into identity EAV:
Mapping:
When the result of the transformation is an empty list (as below), then the value from the identity is not deleted .
List<String> result = new ArrayList<>(); .... return result;
In the version 9.7, this worked well. It stopped working after upgrading to 11.2.1. There is no info about this change in the CHANGELOG.
Workaround: return the value as null. Then the EAV is deleted correctly.
Note: It's interesting that the synchronization tells us that something changes, but in the end, it doesn't make the change:
DEBUG xxxShouldSyncxxxxxPermission attributeValue [] DEBUG xxxShouldSyncxxxxxPermission result [] [base-task-executor-4] e.b.idm.acc.service.impl.AbstractSynchronizationExecutor.addToItemLog : 18.01.2022 17:52:20: Value of EAV attribute [opravneni_xxx] was changed. First change was detected -> entity in IdM will be updated.
Files
Updated by Roman Kučera over 2 years ago
- Target version changed from 12.2.0 to 13.0.0
Updated by Tomáš Doischer over 2 years ago
- Status changed from New to In Progress
- Assignee changed from Peter Štrunc to Tomáš Doischer
Updated by Tomáš Doischer over 2 years ago
- Status changed from In Progress to Needs feedback
- Assignee changed from Tomáš Doischer to Roman Kučera
- % Done changed from 0 to 80
Fixed. This was changed along with the differential synchronization and this case was not covered.
PR: https://github.com/bcvsolutions/CzechIdMng/pull/217
Can you please give me feedback?
Updated by Roman Kučera over 2 years ago
- Status changed from Needs feedback to Resolved
- Assignee changed from Roman Kučera to Tomáš Doischer
- % Done changed from 80 to 100
Thx, works great.
Merged into develop
Updated by Tomáš Doischer almost 2 years ago
- Status changed from Resolved to Closed