1
votes

I'm in the process of upgrading my WebLogic server from 10.3.5 to 12.2.1.2.0 (12c). In addition, I'm updating my code from Java 1.6 version to 1.8, the code build works fine but when the ear file is deployed onto the WebLogic server I get the below stack trace. When checked the deployment on the WebLogic console, I see the state of it as "New". Trying to find out the root cause of this and how to fix it. Below is the whole stack trace. Any help is appreciated.

<AdminServer> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <4b9387e6-fa51-4a9d-976b-39455cbd9d07-00000006> <1499795916830> <[severity-value: 8] [rid: 0] [partition-id: 0] [partition-name: DOMAIN] > <BEA-149205> <Failed to initialize the application "myapp-ear" due to error weblogic.management.DeploymentException: java.lang.IncompatibleClassChangeError: Implementing class
weblogic.management.DeploymentException: java.lang.IncompatibleClassChangeError: Implementing class
    at weblogic.application.internal.BaseDeployment.throwAppException(BaseDeployment.java:132)
    at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:242)
    at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:66)
    at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:158)
    at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:65)
    at weblogic.deploy.internal.targetserver.AppDeployment.prepare(AppDeployment.java:155)
    at weblogic.management.deploy.internal.DeploymentAdapter$1.doPrepare(DeploymentAdapter.java:41)
    at weblogic.management.deploy.internal.DeploymentAdapter.prepare(DeploymentAdapter.java:193)
    at weblogic.management.deploy.internal.AppTransition$1.transitionApp(AppTransition.java:31)
    at weblogic.management.deploy.internal.ConfiguredDeployments$2.doItem(ConfiguredDeployments.java:684)
    at weblogic.management.deploy.internal.parallel.BucketInvoker.invoke(BucketInvoker.java:138)
    at weblogic.management.deploy.internal.ConfiguredDeployments.transitionAppsParallel(ConfiguredDeployments.java:692)
    at weblogic.management.deploy.internal.ConfiguredDeployments.prepare(ConfiguredDeployments.java:322)
    at weblogic.management.deploy.internal.ConfiguredDeployments.deploy(ConfiguredDeployments.java:202)
    at weblogic.management.deploy.internal.DeploymentServerService.resume(DeploymentServerService.java:207)
    at weblogic.management.deploy.internal.DeploymentServerService.start(DeploymentServerService.java:129)
    at weblogic.server.AbstractServerService.postConstruct(AbstractServerService.java:76)
    at sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.glassfish.hk2.utilities.reflection.ReflectionHelper.invoke(ReflectionHelper.java:1262)
    at org.jvnet.hk2.internal.ClazzCreator.postConstructMe(ClazzCreator.java:332)
    at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:374)
    at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:471)
    at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:232)
    at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85)
    at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2020)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:114)
    at org.jvnet.hk2.internal.ServiceLocatorImpl.getService(ServiceLocatorImpl.java:693)
    at org.jvnet.hk2.internal.ThreeThirtyResolver.resolve(ThreeThirtyResolver.java:78)
    at org.jvnet.hk2.internal.ClazzCreator.resolve(ClazzCreator.java:211)
    at org.jvnet.hk2.internal.ClazzCreator.resolveAllDependencies(ClazzCreator.java:234)
    at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:357)
    at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:471)
    at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:232)
    at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85)
    at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2020)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:114)
    at org.jvnet.hk2.internal.ServiceLocatorImpl.getService(ServiceLocatorImpl.java:693)
    at org.jvnet.hk2.internal.ThreeThirtyResolver.resolve(ThreeThirtyResolver.java:78)
    at org.jvnet.hk2.internal.ClazzCreator.resolve(ClazzCreator.java:211)
    at org.jvnet.hk2.internal.ClazzCreator.resolveAllDependencies(ClazzCreator.java:234)
    at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:357)
    at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:471)
    at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:232)
    at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85)
    at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2020)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:114)
    at org.jvnet.hk2.internal.ServiceLocatorImpl.getService(ServiceLocatorImpl.java:693)
    at org.jvnet.hk2.internal.ThreeThirtyResolver.resolve(ThreeThirtyResolver.java:78)
    at org.jvnet.hk2.internal.ClazzCreator.resolve(ClazzCreator.java:211)
    at org.jvnet.hk2.internal.ClazzCreator.resolveAllDependencies(ClazzCreator.java:234)
    at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:357)
    at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:471)
    at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:232)
    at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85)
    at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2020)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:114)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:88)
    at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.oneJob(CurrentTaskFuture.java:1213)
    at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.run(CurrentTaskFuture.java:1144)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:666)
    at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:348)
    at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:333)
    at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:54)
    at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41)
    at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:640)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:406)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:346)
Caused By: java.lang.IncompatibleClassChangeError: Implementing class
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
    at weblogic.utils.classloaders.GenericClassLoader.defineClassInternal(GenericClassLoader.java:1110)
    at weblogic.utils.classloaders.GenericClassLoader.defineClass(GenericClassLoader.java:1043)
    at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:1035)
    at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:987)
    at weblogic.utils.classloaders.GenericClassLoader.doFindClass(GenericClassLoader.java:608)
    at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:540)
    at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:493)
    at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:470)
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
    at weblogic.utils.classloaders.GenericClassLoader.defineClassInternal(GenericClassLoader.java:1110)
    at weblogic.utils.classloaders.GenericClassLoader.defineClass(GenericClassLoader.java:1043)
    at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:1035)
    at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:987)
    at weblogic.utils.classloaders.GenericClassLoader.doFindClass(GenericClassLoader.java:608)
    at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:540)
    at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:493)
    at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:470)
    at weblogic.application.internal.flow.PojoAnnotationProcessingFlow.loadClass(PojoAnnotationProcessingFlow.java:366)
    at weblogic.application.internal.flow.PojoAnnotationProcessingFlow.access$100(PojoAnnotationProcessingFlow.java:58)
    at weblogic.application.internal.flow.PojoAnnotationProcessingFlow$CollectorFilter.accept(PojoAnnotationProcessingFlow.java:341)
    at weblogic.application.utils.annotation.ClassfinderClassInfos.getAnnotatedClasses(ClassfinderClassInfos.java:663)
    at weblogic.application.utils.annotation.ClassfinderClassInfos.getAnnotatedClassesByTargetsAndSources(ClassfinderClassInfos.java:607)
    at weblogic.application.utils.annotation.ClassfinderClassInfos.getAnnotatedClassesByTargetsAndSources(ClassfinderClassInfos.java:582)
    at weblogic.application.internal.flow.PojoAnnotationProcessingFlow.processAnnotations(PojoAnnotationProcessingFlow.java:288)
    at weblogic.application.internal.flow.PojoAnnotationProcessingFlow.processPOJOsInModuleScopes(PojoAnnotationProcessingFlow.java:229)
    at weblogic.application.internal.flow.PojoAnnotationProcessingFlow.prepare(PojoAnnotationProcessingFlow.java:73)
    at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:727)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:45)
    at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:239)
    at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:66)
    at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:158)
    at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:65)
    at weblogic.deploy.internal.targetserver.AppDeployment.prepare(AppDeployment.java:155)
    at weblogic.management.deploy.internal.DeploymentAdapter$1.doPrepare(DeploymentAdapter.java:41)
    at weblogic.management.deploy.internal.DeploymentAdapter.prepare(DeploymentAdapter.java:193)
    at weblogic.management.deploy.internal.AppTransition$1.transitionApp(AppTransition.java:31)
    at weblogic.management.deploy.internal.ConfiguredDeployments$2.doItem(ConfiguredDeployments.java:684)
    at weblogic.management.deploy.internal.parallel.BucketInvoker.invoke(BucketInvoker.java:138)
    at weblogic.management.deploy.internal.ConfiguredDeployments.transitionAppsParallel(ConfiguredDeployments.java:692)
    at weblogic.management.deploy.internal.ConfiguredDeployments.prepare(ConfiguredDeployments.java:322)
    at weblogic.management.deploy.internal.ConfiguredDeployments.deploy(ConfiguredDeployments.java:202)
    at weblogic.management.deploy.internal.DeploymentServerService.resume(DeploymentServerService.java:207)
    at weblogic.management.deploy.internal.DeploymentServerService.start(DeploymentServerService.java:129)
    at weblogic.server.AbstractServerService.postConstruct(AbstractServerService.java:76)
    at sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.glassfish.hk2.utilities.reflection.ReflectionHelper.invoke(ReflectionHelper.java:1262)
    at org.jvnet.hk2.internal.ClazzCreator.postConstructMe(ClazzCreator.java:332)
    at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:374)
    at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:471)
    at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:232)
    at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85)
    at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2020)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:114)
    at org.jvnet.hk2.internal.ServiceLocatorImpl.getService(ServiceLocatorImpl.java:693)
    at org.jvnet.hk2.internal.ThreeThirtyResolver.resolve(ThreeThirtyResolver.java:78)
    at org.jvnet.hk2.internal.ClazzCreator.resolve(ClazzCreator.java:211)
    at org.jvnet.hk2.internal.ClazzCreator.resolveAllDependencies(ClazzCreator.java:234)
    at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:357)
    at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:471)
    at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:232)
    at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85)
    at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2020)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:114)
    at org.jvnet.hk2.internal.ServiceLocatorImpl.getService(ServiceLocatorImpl.java:693)
    at org.jvnet.hk2.internal.ThreeThirtyResolver.resolve(ThreeThirtyResolver.java:78)
    at org.jvnet.hk2.internal.ClazzCreator.resolve(ClazzCreator.java:211)
    at org.jvnet.hk2.internal.ClazzCreator.resolveAllDependencies(ClazzCreator.java:234)
    at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:357)
    at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:471)
    at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:232)
    at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85)
    at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2020)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:114)
    at org.jvnet.hk2.internal.ServiceLocatorImpl.getService(ServiceLocatorImpl.java:693)
    at org.jvnet.hk2.internal.ThreeThirtyResolver.resolve(ThreeThirtyResolver.java:78)
    at org.jvnet.hk2.internal.ClazzCreator.resolve(ClazzCreator.java:211)
    at org.jvnet.hk2.internal.ClazzCreator.resolveAllDependencies(ClazzCreator.java:234)
    at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:357)
    at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:471)
    at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:232)
    at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85)
    at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2020)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:114)
    at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:88)
    at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.oneJob(CurrentTaskFuture.java:1213)
    at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.run(CurrentTaskFuture.java:1144)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:666)
    at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:348)
    at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:333)
    at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:54)
    at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41)
    at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:640)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:406)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:346)
1
One step at a time! If you rush, you will surely crush.nyedidikeke
First, I pointed my code and workspace to java 8 version, compiled and built it. Secondly, I have upgraded my WebLogic server and tried to deploy the app. This is when I get the above error.user7971439
After upgrading WebLogic server from 10.3.5 to 12c: did you run a full test to insure that everything is working as expected? If Yes, there's No point making mention of that in your post as 12c will have simply be the last operational version of your WebLogic server. In other words, your challenge should have been related to updating your code from Java 1.6 version to 1.8. If No, you are chasing two rabbits and this implies that you will likely have a hard time troubleshooting effectively so as to address the challenge you are facing. A word to the wise ...nyedidikeke
Ok, let me do that in a staggered manner, first upgrade WebLogic and make it work and then upgrade Java. Thanks.user7971439
When I have the WebLogic version as 12c, it's not accepting the java version to be 1.8 instead it prompts to select java version 1.6. Looks like I have to point and compile the code with java 1.8 and point the WebLogic to 12c at the same time.user7971439

1 Answers

1
votes

Check the logs of yours servers. There are should be something like:

Exception java.lang.IncompatibleClassChangeError with a message Implementing class

And right before this, thereare should be ClassLoader message with the name of class that is incompatible. Also one note about how to avoid this, update your weblogic.xml and provide in

<prefer-application-packages></prefer-application-packages>

exact packages of libraries that should be used, for examle:

<container-descriptor>
    <prefer-application-packages>
        <package-name>org.apache.commons.logging.*</package-name>
    </prefer-application-packages>
</container-descriptor>

In this case weblogic container will take the classes from package of yours app classpath and not from it's own. More info you can find here: https://docs.oracle.com/cd/E24329_01/web.1211/e21049/weblogic_xml.htm#WBAPP660