[MAGNOLIA-6589] When using DefinitionMetadataBuilder.NameMetadataBuilder() registry API doesn't handle same-name-definitions appropriately Created: 09/Mar/16  Updated: 10/Jul/17  Resolved: 08/Apr/16

Status: Closed
Project: Magnolia
Component/s: configuration
Affects Version/s: 5.4.5
Fix Version/s: 5.4.6

Type: Bug Priority: Major
Reporter: Philip Mundt Assignee: Roman Kovařík
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: 0d
Time Spent: 0.5d
Original Estimate: Not Specified

Issue Links:
Relates
relates to MGNLSITE-48 Create registry for themes to allow t... Closed
causality
is causing MAGNOLIA-7090 Error message when changing a block d... Open
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
Date of First Response:
Sprint: Kromeriz 38
Story Points: 3

 Description   

When using info.magnolia.config.registry.DefinitionMetadataBuilder.NameMetadataBuilder as identification-strategy of items in a registry, it is possible to add more than one element with the same name without getting any errors.

When using names-as-ids, it should be possible to add only one definition with that particular name.



 Comments   
Comment by Roman Kovařík [ 11/Mar/16 ]

info.magnolia.config.registry.RegistryMap#stringKeysMap ends up with different number of items then info.magnolia.config.registry.RegistryMap#map since map uses DefinitionMetadata as key, and stringKeysMap only String.

To reproduce: MGNLSITE-48 - create two themes with the same name.

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