Skip to content

Reject competing read and write accessors for PropertyAccessor and IndexAccessor in SpEL #32737

Open
@sbrannen

Description

@sbrannen

Overview

While working on #26478 and related issues, it became apparent that a developer can inadvertently register one PropertyAccessor for reading a given property and a second competing accessor for writing the same property, which can lead to improper behavior when a cached accessor is expected to be able to support both read and write access for a given property.

The same can happen with multiple competing IndexAccessor implementations.

We have therefore decided to reject competing read and write accessors for the same property or the same index for both PropertyAccessor and IndexAccessor, respectively, starting with Spring Framework 6.2.

Related Issues

Metadata

Metadata

Assignees

Labels

in: coreIssues in core modules (aop, beans, core, context, expression)type: enhancementA general enhancement

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions