gpt4 book ai didi

spring - Spring 安全编译错误

转载 作者:行者123 更新时间:2023-12-03 05:17:41 25 4
gpt4 key购买 nike

我正在尝试使用Gradle编译spring-security 3.2.0。我在spring4测试中遇到错误。

我正在使用以下命令运行编译:

gradlew clean build -x javadoc

这是我的DOS提示符中显示的内容:

609 tests completed, 1 failed :spring-security-config:spring4Test FAILED

FAILURE: Build failed with an exception.

  • What went wrong: Execution failed for task ':spring-security-config:spring4Test'.

    There were failing tests. See the report at: file:///C:/spring/spring-security -3.2.0.RELEASE/config/build/reports/spring4-tests/index.html

  • 尝试:使用--stacktrace选项运行以获取堆栈跟踪。使用--info或--debug选项运行,以获取更多日志输出。


  • 建立失败

    总时间:4分钟21.298秒

    我该如何解决错误?

    这是我的Gradle信息:

    ------------------------------------------------------------ Gradle 1.10-rc-2

    Build time: 2013-12-11 10:54:54 UTC Build number: none Revision:
    36ced393628875ff15575fa03d16c1349ffe8bb6

    Groovy: 1.8.6 Ant: Apache Ant(TM) version 1.9.2 compiled on July 8 2013 Ivy: 2.2.0 JVM: 1.7.0 (Oracle Corporation 21.0-b17) OS: Windows 7 6.1 amd64



    这是上面引用的报告中的内容:

    测试失败
    http / openid-login / attribute-exchange

    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'springSecurityFilterChain' defined in class org.springframework.security.config.annotation.web.configuration.WebSecurityConfiguration: Instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanDefinitionStoreException: Factory method [public javax.servlet.Filter org.springframework.security.config.annotation.web.configuration.WebSecurityConfiguration.springSecurityFilterChain() throws java.lang.Exception] threw exception; nested exception is java.lang.reflect.GenericSignatureFormatError at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:592) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1094) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:989) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:504) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:475) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:304) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:228) at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:300) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:195) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:700) at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:760) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:482) at org.springframework.context.annotation.AnnotationConfigApplicationContext.(AnnotationConfigApplicationContext.java:84) at org.springframework.security.config.annotation.BaseSpringSpec.loadConfig(BaseSpringSpec.groovy:91) at org.springframework.security.config.annotation.web.configurers.NamespaceHttpOpenIDLoginTests.http/openid-login/attribute-exchange(NamespaceHttpOpenIDLoginTests.groovy:79) Caused by: org.springframework.beans.factory.BeanDefinitionStoreException: Factory method [public javax.servlet.Filter org.springframework.security.config.annotation.web.configuration.WebSecurityConfiguration.springSecurityFilterChain() throws java.lang.Exception] threw exception; nested exception is java.lang.reflect.GenericSignatureFormatError at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:188) at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:581) ... 14 more Caused by: java.lang.reflect.GenericSignatureFormatError at java.beans.FeatureDescriptor.getParameterTypes(FeatureDescriptor.java:387) at java.beans.MethodDescriptor.setMethod(MethodDescriptor.java:114) at java.beans.MethodDescriptor.(MethodDescriptor.java:72) at java.beans.MethodDescriptor.(MethodDescriptor.java:56) at java.beans.Introspector.getTargetMethodInfo(Introspector.java:1150) at java.beans.Introspector.getBeanInfo(Introspector.java:433) at java.beans.Introspector.getBeanInfo(Introspector.java:174) at org.springframework.security.config.annotation.web.configurers.NamespaceHttpOpenIDLoginTests$OpenIDLoginAttributeExchangeConfig.configure(NamespaceHttpOpenIDLoginTests.groovy:118) at org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter.getHttp(WebSecurityConfigurerAdapter.java:187) at org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter.init(WebSecurityConfigurerAdapter.java:282) at org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter.init(WebSecurityConfigurerAdapter.java:57) at org.springframework.security.config.annotation.AbstractConfiguredSecurityBuilder.init(AbstractConfiguredSecurityBuilder.java:369) at org.springframework.security.config.annotation.AbstractConfiguredSecurityBuilder.doBuild(AbstractConfiguredSecurityBuilder.java:322) at org.springframework.security.config.annotation.AbstractSecurityBuilder.build(AbstractSecurityBuilder.java:39) at org.springframework.security.config.annotation.web.configuration.WebSecurityConfiguration.springSecurityFilterChain(WebSecurityConfiguration.java:92) at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228) at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:326) at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:166) ... 15 more

最佳答案

这是bug that was fixed in JDK 1.7.0_02及以上版本。

update to the latest JDK 7编译Spring Security。还有许多安全修复程序,应该鼓励您也更新到最新的JDK 7。

关于spring - Spring 安全编译错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21765457/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com