Native: config validation fails at startup with MissingReflectionRegistrationError on GraalVM 25.1 and later
Describe the bug
A native executable built with GraalVM 25.1 or later fails at startup as soon as the application has one config mapping with a Bean Validation constraint (quarkus-hibernate-validator present).
BeanValidationConfigValidator then validates every config mapping, including Quarkus' own ones, and reads each property with Method.invoke on the mapping interface method.
That interface method is not registered for reflective invocation, so the executable stops with a MissingReflectionRegistrationError.
The same executable built with GraalVM CE 25.0.2 or Mandrel 25.0.4.1 starts fine, and the application works in JVM mode.
Expected behavior
The native executable starts, prints Hello from a native config mapping and exits with 0, as it does with GraalVM CE 25.0.2 and Mandrel 25.0.4.1-Final.
Actual behavior
The native executable fails at startup:
ERROR: Failed to start application
java.lang.RuntimeException: Failed to start quarkus
at io.quarkus.runner.ApplicationImpl.doStart(Unknown Source)
at io.quarkus.runtime.Application.start(Application.java:112)
at io.quarkus.runtime.ApplicationLifecycleManager.run(ApplicationLifecycleManager.java:129)
at io.quarkus.runtime.Quarkus.run(Quarkus.java:79)
at io.quarkus.runtime.Quarkus.run(Quarkus.java:50)
at io.quarkus.runner.GeneratedMain.main(Unknown Source)
Caused by: org.graalvm.nativeimage.MissingReflectionRegistrationError: Cannot reflectively invoke method 'public abstract java.util.Optional io.quarkus.runtime.shutdown.ShutdownConfig.delay()'. To allow this operation, add the following to the 'reflection' section of 'reachabilitthe native image:
{
"type": "io.quarkus.runtime.shutdown.ShutdownConfig",
"methods": [
{
"name": "delay",
"parameterTypes": []
}
]
}
at org.graalvm.nativeimage.builder/com.oracle.svm.core.reflect.MissingReflectionRegistrationUtils.reportInvokedExecutable(MissingReflectionRegistrationUtils.java:111)
at [email protected]/java.lang.reflect.Method.acquireMethodAccessor(Method.java:144)
at [email protected]/java.lang.reflect.Method.invoke(Method.java:562)
at io.smallrye.config.validator.BeanValidationConfigValidator.validatePropertyValue(BeanValidationConfigValidator.java:218)
at io.smallrye.config.validator.BeanValidationConfigValidator.validateProperty(BeanValidationConfigValidator.java:78)
at io.smallrye.config.validator.BeanValidationConfigValidator.validatePropertor.java:73)
at io.smallrye.config.validator.BeanValidationConfigValidator.validateMappingInterface(BeanValidationConfigValidator.java:58)
at io.smallrye.config.validator.BeanValidationConfigValidator.validateMappingr.java:40)
at io.smallrye.config.ConfigMappingContext.constructMapping(ConfigMappingContext.java:90)
at io.smallrye.config.ConfigMappingContext.<init>(ConfigMappingContext.java:69)
at io.smallrye.config.SmallRyeConfig$1.get(SmallRyeConfig.java:162)
at io.smallrye.config.SmallRyeConfig$1.get(SmallRyeConfig.java:159)
at io.smallrye.config.SecretKeys.doUnlocked(SecretKeys.java:65)
at io.smallrye.config.SmallRyeConfig.buildMappings(SmallRyeConfig.java:159)
at io.smallrye.config.SmallRyeConfig.<init>(SmallRyeConfig.java:126)
at io.smallrye.config.SmallRyeConfigBuilder.build(SmallRyeConfigBuilder.java:790)
at io.quarkus.runtime.generated.Config.runtimeConfig(Unknown Source)
... 6 moreThe mapping named in the error changes between builds, e.g. ConfigConfig.buildTimeMismatchAtRuntime(), ThreadPoolConfig.coreThreads() or InitRuntimeConfig.initAndExit().
In a larger application it also hits extension mappings such as StorkConfiguration.serviceConfiguration() and OpenApiRuntimeConfig.documents().
How to Reproduce?
Reproducer: https://github.com/ls-bit/quarkus-native-config-validation-reproducer
Steps to reproduce the behavior:
- Point
JAVA_HOME/GRAALVM_HOMEto GraalVM CE 25.1 or later (e.g. 25.4.4.1.1). ./gradlew build -Dquarkus.native.enabled=true -Dquarkus.package.jar.enabled=false./build/quarkus-native-config-validation-reproducer-unspecified-runner
Without the @NotBlank on GreetingConfig.message() the executable starts.
Output of uname -a or ver
Linux (redacted) 6.18.40.1-microsoft-standard-WSL2 #1 SMP PREEMPT_DYNAMIC Fri Jul 31 22:12:15 UTC 2026 x86_64 GNU/Linux
Output of java -version
openjdk version "25.0.4.1.1" 2026-08-18 / OpenJDK Runtime Environment GraalVM CE 25.4.4.1.1+1.1 (build 25.0.4.1.1+1-jvmci-25.4-b23)
Mandrel or GraalVM version (if different from Java)
GraalVM CE 25.4.4.1.1 (also fails with GraalVM CE 25.1.3; works with GraalVM CE 25.0.2 and Mandrel 25.0.4.1-Final)
Quarkus version or git rev
3.40.1 (also 3.38.1 and 3.39.5)
Build tool (ie. output of mvnw --version or gradlew --version)
Gradle 9.6.1
Additional information
| Quarkus | native-image | Result |
|---|---|---|
| 3.38.1 | GraalVM CE 25.0.2 | passes |
| 3.40.1 | GraalVM CE 25.0.2 | passes |
| 3.38.1 | Mandrel 25.0.4.1-Final | passes |
| 3.40.1 | GraalVM CE 25.1.3 | fails |
| 3.38.1 | GraalVM CE 25.4.4.1.1 | fails |
| 3.39.5 | GraalVM CE 25.4.4.1.1 | fails |
| 3.40.1 | GraalVM CE 25.4.4.1.1 | fails |
In a larger application GraalVM CE 25.2.4 and Oracle GraalVM 25.0.4.1 (native-image 25.3) fail the same way.
Source: quarkusio/quarkus