[MAGNOLIA-7364] Map2Bean yields an ArrayList regardless of the collection type declared for the property Created: 30/Aug/18  Updated: 31/Aug/18  Resolved: 31/Aug/18

Status: Closed
Project: Magnolia
Component/s: None
Affects Version/s: None
Fix Version/s: 5.5.13, 5.6.8, 5.7.2, 6.0

Type: Bug Priority: Neutral
Reporter: Aleksandr Pchelintcev Assignee: Aleksandr Pchelintcev
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
dependency
is depended upon by MGNLUI-4519 Migrate select fields to Vaadin 8 Closed
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Epic Link: 6.0 requisite
Sprint: Basel 154
Story Points: 1

 Description   

Map2BeanTransformer#readCollection does not take into account collection type of the property and creates/returns an ArrayList for every case.

We should try to instantiate the configured type first (there's even a map with default impls, which btw needs to be expanded) and fall back to array list only in case of a failure.


Generated at Mon Feb 12 04:23:08 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.