环境:Spring Boot 3.2.1、JDK 21、GraalVM、Spring Native、Spring Security。错误
Microsoft Windows [Version 10.0.22631.2861]
(c) Microsoft Corporation. All rights reserved.
. ____ _ __ _ _
/\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
\\/ ___)| |_)| | | | | || (_| | ) ) ) )
' |____| .__|_| |_|_| |_\__, | / / / /
=========|_|==============|___/=/_/_/_/
:: Spring Boot :: (v3.2.1)
2024-01-09T23:07:03.438+07:00 INFO 34652 --- [
***************************
APPLICATION FAILED TO START
***************************
Description:
The bean 'mvcHandlerMappingIntrospectorRequestTransformer' could not be registered. A bean with that name has already been defined and overriding is disabled.
Action:
Consider renaming one of the beans or enabling overriding by setting spring.main.allow-bean-definition-overriding=true
如何解决?
这是一个由于 Spring Native 编译而导致的已知问题。等待 Spring 3.2.2 或使用快照来解决问题。