admin管理员组

文章数量:1122846

After upgrading spring boot from 3.4.0-M2 to 3.4.0 my native tests started failing. I found that process-aot runs into a StackOverFlow.

Is there something I need to change? or is this a regression?

Exception in thread "main" java.lang.StackOverflowError
    at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.checkReceiver(DirectMethodHandleAccessor.java:196)
    at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:99)
    at java.base/java.lang.reflect.Method.invoke(Method.java:580)
    at org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:281)
    at org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:265)
    at org.springframework.core.SerializableTypeWrapper$MethodInvokeTypeProvider.getType(SerializableTypeWrapper.java:357)
    at org.springframework.core.SerializableTypeWrapper.forTypeProvider(SerializableTypeWrapper.java:106)
    at org.springframework.core.SerializableTypeWrapper$TypeProxyInvocationHandler.invoke(SerializableTypeWrapper.java:215)
    at org.springframework.core.$Proxy6.getActualTypeArguments(Unknown Source)
    at org.springframework.core.ResolvableType.getGenerics(ResolvableType.java:809)
    at org.springframework.core.ResolvableType.getGeneric(ResolvableType.java:762)
    at org.springframework.validation.beanvalidation.BeanValidationBeanRegistrationAotProcessor$BeanValidationDelegate.lambda$processAheadOfTime$0(BeanValidationBeanRegistrationAotProcessor.java:154)
    at org.springframework.util.ReflectionUtils.doWithFields(ReflectionUtils.java:728)
    at org.springframework.util.ReflectionUtils.doWithFields(ReflectionUtils.java:707)
    at org.springframework.validation.beanvalidation.BeanValidationBeanRegistrationAotProcessor$BeanValidationDelegate.processAheadOfTime(BeanValidationBeanRegistrationAotProcessor.java:150)
    at org.springframework.validation.beanvalidation.BeanValidationBeanRegistrationAotProcessor$BeanValidationDelegate.lambda$processAheadOfTime$0(BeanValidationBeanRegistrationAotProcessor.java:170)
    at org.springframework.util.ReflectionUtils.doWithFields(ReflectionUtils.java:728)
    at org.springframework.util.ReflectionUtils.doWithFields(ReflectionUtils.java:707)

After upgrading spring boot from 3.4.0-M2 to 3.4.0 my native tests started failing. I found that process-aot runs into a StackOverFlow.

Is there something I need to change? or is this a regression?

Exception in thread "main" java.lang.StackOverflowError
    at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.checkReceiver(DirectMethodHandleAccessor.java:196)
    at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:99)
    at java.base/java.lang.reflect.Method.invoke(Method.java:580)
    at org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:281)
    at org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:265)
    at org.springframework.core.SerializableTypeWrapper$MethodInvokeTypeProvider.getType(SerializableTypeWrapper.java:357)
    at org.springframework.core.SerializableTypeWrapper.forTypeProvider(SerializableTypeWrapper.java:106)
    at org.springframework.core.SerializableTypeWrapper$TypeProxyInvocationHandler.invoke(SerializableTypeWrapper.java:215)
    at org.springframework.core.$Proxy6.getActualTypeArguments(Unknown Source)
    at org.springframework.core.ResolvableType.getGenerics(ResolvableType.java:809)
    at org.springframework.core.ResolvableType.getGeneric(ResolvableType.java:762)
    at org.springframework.validation.beanvalidation.BeanValidationBeanRegistrationAotProcessor$BeanValidationDelegate.lambda$processAheadOfTime$0(BeanValidationBeanRegistrationAotProcessor.java:154)
    at org.springframework.util.ReflectionUtils.doWithFields(ReflectionUtils.java:728)
    at org.springframework.util.ReflectionUtils.doWithFields(ReflectionUtils.java:707)
    at org.springframework.validation.beanvalidation.BeanValidationBeanRegistrationAotProcessor$BeanValidationDelegate.processAheadOfTime(BeanValidationBeanRegistrationAotProcessor.java:150)
    at org.springframework.validation.beanvalidation.BeanValidationBeanRegistrationAotProcessor$BeanValidationDelegate.lambda$processAheadOfTime$0(BeanValidationBeanRegistrationAotProcessor.java:170)
    at org.springframework.util.ReflectionUtils.doWithFields(ReflectionUtils.java:728)
    at org.springframework.util.ReflectionUtils.doWithFields(ReflectionUtils.java:707)
Share Improve this question asked Nov 22, 2024 at 10:42 EiswindEiswind 1512 silver badges6 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

This is due to a regression in Spring Framework 6.2.0. There's no known workaround at this time.

本文标签: Spring processaot fails with StackOverFlow after upgrade from 340M2 to 340Stack Overflow