It will be a great feature to provide a direct support of vavr types (immutable collections, Iterables, Option..) like it exists on Spring Data for classes annotated with @ConfigurationProperties
and fields annotated with @Value
.
Comment From: wilkinsona
Thanks for the suggestion.
To allow both Spring Boot and Spring Data to make use of the same Vavr support, I think it would make most sense if it became a feature of the core Framework. There are a couple of Vavr-related issues already open:
- https://github.com/spring-projects/spring-framework/issues/21073
- https://github.com/spring-projects/spring-framework/issues/21337
In the meantime, you may be able to implement support for @ConfigurationProperties
yourself by taking some inspiration from Spring Data and providing one or more Converter
beans that are annotated with @ConfigurationPropertiesBinding
.