簡體   English   中英

使用 SAML 的 spring boot 應用程序在 weblogic 中的部署問題

[英]Deployment issue in weblogic for spring boot application with SAML

您好,我正在嘗試將基於 spring boot 版本:1.5 的 Spring boot 應用程序部署到 weblogic 12C(12.1.3.0.0),它工作正常,直到最近集成了 SAML2,一旦集成部署開始失敗。

它在 Tomcat8.5 容器中工作正常

那么如何找到導致問題的原因

[ACTIVE] ExecuteThread: 2 for queue: weblogic.kernel.Default (self-tuning),logClass:osboot.SpringApplication,logMethod:reportFailure,logLevel:ERROR,logMessage:Application startup failed,logException:java.lang.IncompatibleClassChangeError: Implementing class\n\tat java.lang.ClassLoader.defineClass1(Native Method)\n\tat java.lang.ClassLoader.defineClass(ClassLoader.java:760)\n\tat java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)\n\tat weblogic.utils.classloaders.GenericClassLoader.defineClass(GenericClassLoader.java:412)\n\tat weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:366)\n\tat weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:318)\n\tat weblogic.utils.classloaders.ChangeAwareClassLoader.findClass(ChangeAwareClassLoader.java:80)\n\tat java.lang.ClassLoader.loadClass(ClassLoader.java:424)\n\tat java.lang.ClassLoader.loadClass(ClassLoader.java:357)\n\tat weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:186)\n\tat weblogic.utils.classloaders.ChangeAwareClassLoader.loadClass(ChangeAwareClassLoader.java:50)\n\tat java.lang.Class.getDeclaredMethods0(Native Method)\n\tat java.lang.Class.privateGetDeclaredMethods(Class.java:2701)\n\tat java.lang.Class.getDeclaredMethods(Class.java:1975)\n\tat org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:612)\n\tat org.springframework.util.ReflectionUtils.doWithMethods(ReflectionUtils.java:523)\n\tat org.springframework.util.ReflectionUtils.doWithMethods(ReflectionUtils.java:509)\n\tat org.springframework.util.ReflectionUtils.getUniqueDeclaredMethods(ReflectionUtils.java:569)\n\tat org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.getTypeForFactoryMethod(AbstractAutowireCapableBeanFactory.java:695)\n\tat org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineTargetType(AbstractAutowireCapableBeanFactory.java:638)\n\tat org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.predictBeanType(AbstractAutowireCapableBeanFactory.java:607)\n\tat org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:1496)\n\tat org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:1018)\n\tat org.springframework.boot.autoconfigure.condition.BeanTypeRegistry.addBeanTypeForNonAliasDefinition(BeanTypeRegistry.java:217)\n\tat org.springframework.boot.autoconfigure.condition.BeanTypeRegistry.addBeanTypeForNonAliasDefinition(BeanTypeRegistry.java:195)\n\tat org.springframework.boot.autoconfigure.condition.BeanTypeRegistry.addBeanType(BeanTypeRegistry.java:188)\n\tat org.springframework.boot.autoconfigure.condition.BeanTypeRegistry.updateTypesIfNecessary(BeanTypeRegistry.java:175)\n\tat org.springframework.boot.autoconfigure.condition.BeanTypeRegistry.getNamesForType(BeanTypeRegistry.java:112)\n\tat org.springframework.boot.autoconfigure.condition.OnBeanCondition.collectBeanNamesForType(OnBeanCondition.java:171)\n\tat org.springframework.boot.autoconfigure.condition.OnBeanCondition.getBeanNamesForType(OnBeanCondition.java:158)\n\tat org.springframework.boot.autoconfigure.condition.OnBeanCondition.getMatchingBeans(OnBeanCondition.java:128)\n\tat org.springframework.boot.autoconfigure.condition.OnBeanCondition.getMatchOutcome(OnBeanCondition.java:103)\n\tat org.springframework.boot.autoconfigure.condition.SpringBootCondition.matches(SpringBootCondition.java:47)\n\tat org.springframework.context.annotation.ConditionEvaluator.shouldSkip(ConditionEvaluator.java:102)\n\tat org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsForBeanMethod(ConfigurationClassBeanDefinitionReader.java:179)\n\tat org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsForConfigurationClass(ConfigurationClassBeanDefinitionReader.java:140)\n\tat org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitions(ConfigurationClassBeanDefinitionReader.java:116)\n\tat org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:320)\n\tat org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:228)\n\tat org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:272)\n\tat org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:92)\n\tat org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:687)\n\tat org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:524)\n\tat org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:123)\n\tat org.springframework.boot.SpringApplication.refresh(SpringApplication.java:666)\n\tat org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:353)\n\tat org.springframework.boot.SpringApplication.run(SpringApplication.java:300)\n\tat org.springframework.boot.web.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:151)\n\tat org.springframework.boot.web.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:131)\n\tat org.springframework.boot.web.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:91)\n\tat org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:169)\n\tat

項目中使用的依賴jar如下

enter code here

SparseBitSet-1.2.jar
activation-1.1.jar
ant-1.6.5.jar
antlr-2.7.7.jar
aopalliance-1.0.jar
aopalliance-repackaged-2.5.0-b32.jar
aspectjrt-1.6.10.jar
aspectjweaver-1.8.1.jar
autopass-lems-client-1.22.0.jar
bcpkix-jdk15on-1.55.jar
bcprov-jdk15-1.46.jar
bcprov-jdk15on-1.55.jar
classmate-1.3.4.jar
commons-codec-1.10.jar
commons-collections-3.2.2.jar
commons-collections4-4.4.jar
commons-compress-1.19.jar
commons-configuration-1.10.jar
commons-discovery-0.4.jar
commons-httpclient-3.1.jar
commons-lang-2.6.jar
commons-logging-1.2.jar
commons-math3-3.6.1.jar
commons-pool2-2.4.3.jar
curvesapi-1.06.jar
dom4j-1.6.1.jar
encoder-1.2.2.jar
encoder-jsp-1.2.2.jar
esapi-2.0.1.jar
freemarker-2.3.29.jar
guava-20.0.jar
hibernate-commons-annotations-5.0.1.Final.jar
hibernate-core-5.0.12.Final.jar
hibernate-entitymanager-5.0.12.Final.jar
hibernate-jpa-2.1-api-1.0.0.Final.jar
hibernate-validator-5.3.6.Final.jar
hk2-api-2.5.0-b32.jar
hk2-locator-2.5.0-b32.jar
hk2-utils-2.5.0-b32.jar
httpclient-4.3.4.jar
httpcore-4.4.11.jar
itext-asian-5.2.0.jar
itextpdf-5.5.4.jar
jackson-annotations-2.9.4.jar
jackson-core-2.9.4.jar
jackson-core-asl-1.9.13.jar
jackson-databind-2.9.4.jar
jackson-dataformat-csv-2.9.6.jar
jackson-mapper-asl-1.9.13.jar
jandex-2.0.0.Final.jar
javassist-3.21.0-GA.jar
javax.annotation-api-1.2.jar
javax.inject-2.5.0-b32.jar
javax.mail-1.5.2.jar
javax.servlet.jsp.jstl-api-1.2.1.jar
javax.transaction-api-1.2.jar
javax.ws.rs-api-2.0.1.jar
jboss-logging-3.3.2.Final.jar
jcl-over-slf4j-1.6.6.jar
jedis-3.3.0.jar
jersey-client-2.25.1.jar
jersey-common-2.25.1.jar
jersey-guava-2.25.1.jar
joda-time-2.4.jar
jstl-1.2.jar
jul-to-slf4j-1.7.26.jar
log4j-over-slf4j-1.7.26.jar
logback-access-1.1.10.jar
logback-classic-1.2.3.jar
logback-core-1.2.3.jar
logback-jackson-0.1.5.jar
logback-json-classic-0.1.5.jar
logback-json-core-0.1.5.jar
logstash-logback-encoder-6.6.jar
mf-utils-core-1.0.3.jar
modelmapper-2.3.2.jar
not-yet-commons-ssl-0.3.9.jar
opensaml-2.6.1.jar
openws-1.5.1.jar
org.json-20131017.jar
osgi-resource-locator-1.0.1.jar
owasp-java-html-sanitizer-20191001.1.jar
poi-4.1.2.jar
poi-ooxml-4.1.2.jar
poi-ooxml-schemas-4.1.2.jar
resilience4j-core-1.6.1.jar
resilience4j-retry-1.6.1.jar
serializer-2.7.1.jar
sitemesh-2.4.2.jar
slf4j-api-1.7.5.jar
snakeyaml-1.17.jar
spring-aop-4.3.25.RELEASE.jar
spring-aspects-4.3.25.RELEASE.jar
spring-beans-4.3.25.RELEASE.jar
spring-boot-1.5.22.RELEASE.jar
spring-boot-actuator-1.5.22.RELEASE.jar
spring-boot-autoconfigure-1.5.22.RELEASE.jar
spring-boot-configuration-processor-1.5.22.RELEASE.jar
spring-boot-starter-1.5.22.RELEASE.jar
spring-boot-starter-actuator-1.5.22.RELEASE.jar
spring-boot-starter-aop-1.5.22.RELEASE.jar
spring-boot-starter-data-jpa-1.5.22.RELEASE.jar
spring-boot-starter-jdbc-1.5.22.RELEASE.jar
spring-boot-starter-logging-1.5.22.RELEASE.jar
spring-boot-starter-security-1.5.22.RELEASE.jar
spring-boot-starter-web-1.5.22.RELEASE.jar
spring-cloud-commons-1.3.6.RELEASE.jar
spring-cloud-config-client-1.4.5.RELEASE.jar
spring-cloud-context-1.3.6.RELEASE.jar
spring-cloud-sleuth-core-1.3.6.RELEASE.jar
spring-cloud-starter-1.3.6.RELEASE.jar
spring-cloud-starter-config-1.4.5.RELEASE.jar
spring-cloud-starter-sleuth-1.3.6.RELEASE.jar
spring-context-4.3.25.RELEASE.jar
spring-context-support-4.3.25.RELEASE.jar
spring-core-4.3.25.RELEASE.jar
spring-data-commons-1.13.23.RELEASE.jar
spring-data-jpa-1.11.23.RELEASE.jar
spring-expression-4.3.25.RELEASE.jar
spring-jdbc-4.3.25.RELEASE.jar
spring-orm-4.3.25.RELEASE.jar
spring-oxm-4.3.25.RELEASE.jar
spring-security-acl-4.2.13.RELEASE.jar
spring-security-config-4.2.13.RELEASE.jar
spring-security-core-4.2.13.RELEASE.jar
spring-security-crypto-4.2.13.RELEASE.jar
spring-security-rsa-1.0.3.RELEASE.jar
spring-security-saml-dsl-1.0.0.M1.jar
spring-security-saml2-core-1.0.1.RELEASE.jar
spring-security-taglibs-4.2.11.RELEASE.jar
spring-security-web-4.2.13.RELEASE.jar
spring-tx-4.3.25.RELEASE.jar
spring-web-4.3.25.RELEASE.jar
spring-webmvc-4.3.25.RELEASE.jar
tomcat-jdbc-8.5.43.jar
tomcat-juli-8.5.43.jar
validation-api-1.1.0.Final.jar
vavr-0.10.2.jar
vavr-match-0.10.2.jar
velocity-1.7.jar
webApplicationSiteUtil-1.0.0.jar
wsLog-1.1.1.jar
xalan-2.7.1.jar
xercesImpl-2.10.0.jar
xml-apis-1.4.01.jar
xml-resolver-1.2.jar
xmlbeans-3.1.0.jar
xmlsec-1.5.6.jar
xmltooling-1.4.1.jar
xmlworker-5.4.1.jar

在 weblogic.xml 中添加了 prefer-application-packages

<wls:prefer-application-packages>
<wls:package-name>org.apache.xerces.xni.parser.*</wls:package-name>
<wls:package-name>org.apache.xerces.parsers.*</wls:package-name>
<wls:package-name>org.apache.xalan.*</wls:package-name>

</wls:prefer-application-packages>

並且部署工作正常

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM