Skip to content

members of Interface TypeInformation are null when AOP and Data Rest are enabled and a bean is marked @Lazy #3086

Open
@james-bryant

Description

@james-bryant

I have encountered a very strange issue and I'm not sure what to make of it.
It seems that: if AOP is enabled, Spring Data Rest is enabled, and a bean is marked @lazy, then the constants in TypeInformation return null instead of thier expected values.
I was able to create an example project that can reproduce the issue. I went ahead and submitted that to the Spring Boot guys and they sent me over here: spring-projects/spring-boot#40510
Here is the example project, it contains both my original test to reproduce it and the newer test created by the Spring Boot guys:
lazy-proxy-issue.zip

In the first test, you can work around the issue by removing the @lazy annotation from the bean. In the second test, removing the assignment to 'whatever' will work around the issue, as described in the ticket.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions