spring-native icon indicating copy to clipboard operation
spring-native copied to clipboard

@Value and SystemProperties

Open richvim opened this issue 4 years ago • 1 comments

Describe the issue

My existing codebase uses the @Value("#{systemProperties['foo']?:'bar'}") pattern to load configuration properties. The application compiles as a Graal Native Image, but it is unable to read these system properties, no matter how I pass them in (at compile time, or at run time, or as environment variables.)

I read the documentation here, but it doesn't seem to cover my use case.

What's going on here?

Describe GraalVM and your environment:

Latest Graal, OSX.

richvim avatar Feb 19 '21 17:02 richvim

Where do you define those system properties?

sdeleuze avatar Feb 22 '21 15:02 sdeleuze

Spring Native is now superseded by Spring Boot 3 official native support, see the related reference documentation for more details.

As a consequence, I am closing this issue, and recommend trying your use case with latest Spring Boot 3 version. If you still experience the issue reported here, please open an issue directly on the related Spring project (Spring Framework, Data, Security, Boot, Cloud, etc.) with a reproducer.

Thanks for your contribution on the experimental Spring Native project, we hope you will enjoy the official native support introduced by Spring Boot 3.

sdeleuze avatar Jan 02 '23 12:01 sdeleuze