This repository has been archived by the owner on Feb 23, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 354
@ConfigurationProperties with @Validated - native build fails when annotations present on a record #1462
Labels
Comments
Could you please try with:
To qualify more precisely the source of the error? |
|
I tried some experimentation and it seems that when the configuration is a bit more "complex" (multilayered), configuration values are not bound to properties. e.g.
Records:
In native image the Removing one layer:
and the line is printed. |
Notice it works with:
I have asked a feedback to Boot team to refine Spring native handling for that use case. |
The proxy issue is likely a duplicate of #969, I will create another one for the proper nested record detection. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Suppose I have
application.properties
with this linethat I want to map with
@ConfigurationProperties
but instead of a class I place the annotation on a record (which is OK with Spring Boot)The AOT processor tries to proxy it and fails as it cannot be done.
Spring Boot: 2.6.2
Spring Native: 0.11.1
GraalVM: 21.3.0 CE
The text was updated successfully, but these errors were encountered: