getting noclassdeffounderror for class settablefuture仅在websphere中的guava-30.0-jre.jar的com.google.common.util.concurrent包中存在

o2rvlv0m  于 2021-07-12  发布在  Java
关注(0)|答案(0)|浏览(355)

在启用类跟踪时,发现websphere正在从同一个guava-30.0-jre.jar加载同一包(com.google.common.util.concurrent)中的其他类
com.google.common.util.concurrent包中的类总数:310,加载的类总数:285(根据类加载跟踪)
尝试的解决方案:
类加载顺序设置为父级最后一个
在applicationservers>server1>processdefinition>javavirtualmachine下的genericjvm参数中显式设置jar路径
还尝试创建一个共享库,并通过部署的web应用引用它。创建共享库所遵循的步骤来自此url
jar文件也可以,反编译没有任何问题
机器重新启动
下面是一个堆栈跟踪以供参考:

Caused by: java.lang.NoClassDefFoundError: com/google/common/util/concurrent/SettableFuture
at com.google.common.cache.LocalCache$LoadingValueReference.<init>(LocalCache.java:3472) ~[?:?]
at com.google.common.cache.LocalCache$LoadingValueReference.<init>(LocalCache.java:3476) ~[?:?]
at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2134) ~[?:?]
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2045) ~[?:?]
at com.google.common.cache.LocalCache.get(LocalCache.java:3951) ~[?:?]
at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:3974) ~[?:?]
at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:4935) ~[?:?]
at com.google.common.cache.LocalCache$LocalLoadingCache.getUnchecked(LocalCache.java:4941) ~[?:?]
at com.google.inject.internal.Annotations$AnnotationChecker.hasAnnotations(Annotations.java:248) ~[guice-4.0.jar:?]
at com.google.inject.internal.Annotations.isBindingAnnotation(Annotations.java:314) ~[guice-4.0.jar:?]
at com.google.inject.internal.Annotations.findBindingAnnotation(Annotations.java:295) ~[guice-4.0.jar:?]
at com.google.inject.internal.ProviderMethodsModule.getKey(ProviderMethodsModule.java:280) ~[guice-4.0.jar:?]
at com.google.inject.internal.ProviderMethodsModule.createProviderMethod(ProviderMethodsModule.java:264) ~[guice-4.0.jar:?]
at com.google.inject.internal.ProviderMethodsModule.getProviderMethods(ProviderMethodsModule.java:144) ~[guice-4.0.jar:?]
at com.google.inject.internal.ProviderMethodsModule.configure(ProviderMethodsModule.java:123) ~[guice-4.0.jar:?]
at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:340) ~[guice-4.0.jar:?]
at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:349) ~[guice-4.0.jar:?]
at com.google.inject.spi.Elements.getElements(Elements.java:110) ~[guice-4.0.jar:?]
at com.google.inject.internal.InjectorShell$Builder.build(InjectorShell.java:138) ~[guice-4.0.jar:?]
at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:104) ~[guice-4.0.jar:?]
at com.google.inject.Guice.createInjector(Guice.java:96) ~[guice-4.0.jar:?]
at com.google.inject.Guice.createInjector(Guice.java:73) ~[guice-4.0.jar:?]

请注意,当在weblogic、tomcat和jboss中部署相同的web应用程序时,一切正常

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题