Skip to content

ValidatingMongoEventListener doesn't work with LazyLoadingProxy [DATAMONGO-1393] #2306

Closed
@spring-projects-issues

Description

@spring-projects-issues

Paul Sterl opened DATAMONGO-1393 and commented

Basically the following line is missing in the ValidatingMongoEventListener:

final Object target = obj instanceof LazyLoadingProxy ? ((LazyLoadingProxy) obj).getTarget() : obj;

as otherwise the validation is done on the proxy object and so always fails.

Details:

http://sterl.org/2016/03/spring-data-mongodb-jsr-validation/


Affects: 1.8.4 (Gosling SR4)

Reference URL: http://sterl.org/2016/03/spring-data-mongodb-jsr-validation/

Referenced from: pull request #350

Metadata

Metadata

Assignees

Labels

in: coreIssues in core supportin: mappingMapping and conversion infrastructurestatus: declinedA suggestion or change that we don't feel we should currently applytype: bugA general bug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions