Could not be processed by Zeroturnaround JRebel - spring

Env:
JRebel for Eclipse 7.0.11
Eclipse Java EE IDE for Web Developers. Version: Mars.2 Release (4.5.2) Build id: 20160218-0600
Spring 4.2.7.RELEASE
If I used the JRebel, I got this error:
2017-07-11 01:07:30 JRebel: ERROR Class 'org.springframework.web.servlet.DispatcherServlet' could not be processed by org.zeroturnaround.javarebel.integration.spring.cbp.DispatcherServletCBP#org.apache.catalina.loader.WebappClassLoader#6524bbeb: java.lang.RuntimeException: org.zeroturnaround.bundled.javassist.NotFoundException: org.springframework.context.ApplicationContextAware
at org.zeroturnaround.bundled.javassist.CtClassType.getClassFile3(SourceFile:213)
at org.zeroturnaround.bundled.javassist.CtClassType.makeFieldCache(SourceFile:900)
at org.zeroturnaround.bundled.javassist.CtClassType.getMembers(SourceFile:891)
at org.zeroturnaround.bundled.javassist.CtClassType.getDeclaredField2(SourceFile:1025)
at org.zeroturnaround.bundled.javassist.CtClassType.getField2(SourceFile:979)
at org.zeroturnaround.bundled.javassist.CtClassType.getField2(SourceFile:987)
at org.zeroturnaround.bundled.javassist.CtClassType.getField2(SourceFile:994)
at org.zeroturnaround.bundled.javassist.CtClassType.getField(SourceFile:960)
at org.zeroturnaround.bundled.javassist.CtClass.getField(SourceFile:835)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.fieldAccess(SourceFile:837)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atFieldRead(SourceFile:803)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atMember(SourceFile:988)
at org.zeroturnaround.bundled.javassist.compiler.JvstTypeChecker.atMember(SourceFile:66)
at org.zeroturnaround.bundled.javassist.compiler.ast.Member.accept(SourceFile:39)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atCallExpr(SourceFile:665)
at org.zeroturnaround.bundled.javassist.compiler.JvstTypeChecker.atCallExpr(SourceFile:157)
at org.zeroturnaround.bundled.javassist.compiler.ast.CallExpr.accept(SourceFile:46)
at org.zeroturnaround.bundled.javassist.compiler.CodeGen.doTypeCheck(SourceFile:242)
at org.zeroturnaround.bundled.javassist.compiler.CodeGen.atStmnt(SourceFile:330)
at org.zeroturnaround.bundled.javassist.compiler.ast.Stmnt.accept(SourceFile:50)
at org.zeroturnaround.bundled.javassist.compiler.CodeGen.atStmnt(SourceFile:351)
at org.zeroturnaround.bundled.javassist.compiler.ast.Stmnt.accept(SourceFile:50)
at org.zeroturnaround.bundled.javassist.compiler.Javac.compileStmnt(SourceFile:567)
at org.zeroturnaround.bundled.javassist.CtBehavior.insertAfterAdvice(SourceFile:892)
at org.zeroturnaround.bundled.javassist.CtBehavior.insertAfter(SourceFile:851)
at org.zeroturnaround.bundled.javassist.CtBehavior.insertAfter(SourceFile:792)
at org.zeroturnaround.javarebel.integration.spring.cbp.DispatcherServletCBP.process(DispatcherServletCBP.java:44)
at org.zeroturnaround.javarebel.integration.support.JavassistClassBytecodeProcessor.process(SourceFile:78)
at com.zeroturnaround.javarebel.tt.a(SourceFile:376)
at com.zeroturnaround.javarebel.tt.a(SourceFile:365)
at com.zeroturnaround.javarebel.tt.a(SourceFile:322)
at com.zeroturnaround.javarebel.SDKIntegrationImpl.runBytecodeProcessors(SourceFile:34)
at com.zeroturnaround.javarebel.rh.transform(SourceFile:106)
at java.lang.ClassLoader.defineClass(ClassLoader.java)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2888)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1172)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1680)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1558)
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2671)
at java.lang.Class.getConstructor0(Class.java:3075)
at java.lang.Class.newInstance(Class.java:412)
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:152)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5280)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:748)
Caused by: org.zeroturnaround.bundled.javassist.NotFoundException: org.springframework.context.ApplicationContextAware
at org.zeroturnaround.bundled.javassist.CtClassType.getClassFile3(SourceFile:201)
... 51 more
2017-07-11 01:07:30 JRebel: ERROR Class 'ch.qos.logback.core.ContextBase' could not be processed by org.zeroturnaround.jrebel.integration.logback.cbp.ContextBaseCBP#org.apache.catalina.loader.WebappClassLoader#6524bbeb: java.lang.RuntimeException: org.zeroturnaround.bundled.javassist.NotFoundException: ch.qos.logback.core.Context
at org.zeroturnaround.bundled.javassist.CtClassType.getClassFile3(SourceFile:213)
at org.zeroturnaround.bundled.javassist.CtClassType.makeFieldCache(SourceFile:900)
at org.zeroturnaround.bundled.javassist.CtClassType.getMembers(SourceFile:891)
at org.zeroturnaround.bundled.javassist.CtClassType.getDeclaredField2(SourceFile:1025)
at org.zeroturnaround.bundled.javassist.CtClassType.getField2(SourceFile:979)
at org.zeroturnaround.bundled.javassist.CtClassType.getField2(SourceFile:987)
at org.zeroturnaround.bundled.javassist.CtClassType.getField(SourceFile:960)
at org.zeroturnaround.bundled.javassist.CtClass.getField(SourceFile:835)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.fieldAccess(SourceFile:837)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atFieldRead(SourceFile:803)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atMember(SourceFile:988)
at org.zeroturnaround.bundled.javassist.compiler.JvstTypeChecker.atMember(SourceFile:66)
at org.zeroturnaround.bundled.javassist.compiler.ast.Member.accept(SourceFile:39)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atCallExpr(SourceFile:665)
at org.zeroturnaround.bundled.javassist.compiler.JvstTypeChecker.atCallExpr(SourceFile:157)
at org.zeroturnaround.bundled.javassist.compiler.ast.CallExpr.accept(SourceFile:46)
at org.zeroturnaround.bundled.javassist.compiler.CodeGen.doTypeCheck(SourceFile:242)
at org.zeroturnaround.bundled.javassist.compiler.CodeGen.atStmnt(SourceFile:330)
at org.zeroturnaround.bundled.javassist.compiler.ast.Stmnt.accept(SourceFile:50)
at org.zeroturnaround.bundled.javassist.compiler.Javac.compileStmnt(SourceFile:567)
at org.zeroturnaround.bundled.javassist.CtBehavior.insertAfterAdvice(SourceFile:892)
at org.zeroturnaround.bundled.javassist.CtBehavior.insertAfter(SourceFile:851)
at org.zeroturnaround.bundled.javassist.CtBehavior.insertAfter(SourceFile:792)
at org.zeroturnaround.javarebel.integration.support.CBPs$DirectProcessorImpl.insertAfterLeafCtors(SourceFile:229)
at org.zeroturnaround.jrebel.integration.logback.cbp.ContextBaseCBP.process(ContextBaseCBP.java:12)
at org.zeroturnaround.javarebel.integration.support.JavassistClassBytecodeProcessor.process(SourceFile:78)
at com.zeroturnaround.javarebel.tt.a(SourceFile:376)
at com.zeroturnaround.javarebel.tt.a(SourceFile:365)
at com.zeroturnaround.javarebel.tt.a(SourceFile:322)
at com.zeroturnaround.javarebel.SDKIntegrationImpl.runBytecodeProcessors(SourceFile:34)
at com.zeroturnaround.javarebel.rh.transform(SourceFile:106)
at java.lang.ClassLoader.defineClass(ClassLoader.java)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2888)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1172)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1680)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1558)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:348)
at com.zeroturnaround.javarebel.rp.a(SourceFile:118)
at com.zeroturnaround.javarebel.rp.a(SourceFile:299)
at com.zeroturnaround.javarebel.rh.transform(SourceFile:122)
at java.lang.ClassLoader.defineClass(ClassLoader.java)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2888)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1172)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1680)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1558)
at org.slf4j.impl.StaticLoggerBinder.<init>(StaticLoggerBinder.java:59)
at org.slf4j.impl.StaticLoggerBinder.<clinit>(StaticLoggerBinder.java:50)
at org.slf4j.LoggerFactory.bind(LoggerFactory.java:150)
at org.slf4j.LoggerFactory.performInitialization(LoggerFactory.java:124)
at org.slf4j.LoggerFactory.getILoggerFactory(LoggerFactory.java:412)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:357)
at org.apache.commons.logging.impl.SLF4JLogFactory.getInstance(SLF4JLogFactory.java:155)
at org.apache.commons.logging.impl.SLF4JLogFactory.getInstance(SLF4JLogFactory.java:132)
at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:351)
at org.springframework.web.context.AbstractContextLoaderInitializer.<init>(AbstractContextLoaderInitializer.java:44)
at org.springframework.web.servlet.support.AbstractDispatcherServletInitializer.<init>(AbstractDispatcherServletInitializer.java:60)
at org.springframework.web.servlet.support.AbstractAnnotationConfigDispatcherServletInitializer.<init>(AbstractAnnotationConfigDispatcherServletInitializer.java:39)
at id.co.bippo.springapp.BippoWebAppInitializer.<init>(BippoWebAppInitializer.java:34)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.__newInstance(DelegatingConstructorAccessorImpl.java:45)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at java.lang.Class.newInstance(Class.java:442)
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:152)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5280)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:748)
Caused by: org.zeroturnaround.bundled.javassist.NotFoundException: ch.qos.logback.core.Context
at org.zeroturnaround.bundled.javassist.CtClassType.getClassFile3(SourceFile:201)
... 76 more
and
2017-07-11 01:07:34 JRebel: ERROR Class 'org.springframework.core.type.classreading.CachingMetadataReaderFactory' could not be processed by org.zeroturnaround.javarebel.integration.spring.core.cbp.CachingMetadataReaderFactoryCBP#org.apache.catalina.loader.WebappClassLoader#6524bbeb: java.lang.RuntimeException: org.zeroturnaround.bundled.javassist.NotFoundException: org.springframework.core.type.classreading.MetadataReaderFactory
at org.zeroturnaround.bundled.javassist.CtClassType.getClassFile3(SourceFile:213)
at org.zeroturnaround.bundled.javassist.CtClassType.makeFieldCache(SourceFile:900)
at org.zeroturnaround.bundled.javassist.CtClassType.getMembers(SourceFile:891)
at org.zeroturnaround.bundled.javassist.CtClassType.getDeclaredField2(SourceFile:1025)
at org.zeroturnaround.bundled.javassist.CtClassType.getField2(SourceFile:979)
at org.zeroturnaround.bundled.javassist.CtClassType.getField2(SourceFile:987)
at org.zeroturnaround.bundled.javassist.CtClassType.getField2(SourceFile:994)
at org.zeroturnaround.bundled.javassist.CtClassType.getField(SourceFile:960)
at org.zeroturnaround.bundled.javassist.CtClass.getField(SourceFile:835)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.fieldAccess(SourceFile:837)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atFieldRead(SourceFile:803)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atMember(SourceFile:988)
at org.zeroturnaround.bundled.javassist.compiler.JvstTypeChecker.atMember(SourceFile:66)
at org.zeroturnaround.bundled.javassist.compiler.ast.Member.accept(SourceFile:39)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atCallExpr(SourceFile:665)
at org.zeroturnaround.bundled.javassist.compiler.JvstTypeChecker.atCallExpr(SourceFile:157)
at org.zeroturnaround.bundled.javassist.compiler.ast.CallExpr.accept(SourceFile:46)
at org.zeroturnaround.bundled.javassist.compiler.TypeChecker.atCallExpr(SourceFile:665)
at org.zeroturnaround.bundled.javassist.compiler.JvstTypeChecker.atCallExpr(SourceFile:157)
at org.zeroturnaround.bundled.javassist.compiler.ast.CallExpr.accept(SourceFile:46)
at org.zeroturnaround.bundled.javassist.compiler.CodeGen.doTypeCheck(SourceFile:242)
at org.zeroturnaround.bundled.javassist.compiler.CodeGen.atStmnt(SourceFile:330)
at org.zeroturnaround.bundled.javassist.compiler.ast.Stmnt.accept(SourceFile:50)
at org.zeroturnaround.bundled.javassist.compiler.Javac.compileStmnt(SourceFile:567)
at org.zeroturnaround.bundled.javassist.CtBehavior.insertAfterAdvice(SourceFile:892)
at org.zeroturnaround.bundled.javassist.CtBehavior.insertAfter(SourceFile:851)
at org.zeroturnaround.bundled.javassist.CtBehavior.insertAfter(SourceFile:792)
at org.zeroturnaround.javarebel.integration.spring.core.cbp.CachingMetadataReaderFactoryCBP.process(CachingMetadataReaderFactoryCBP.java:26)
at org.zeroturnaround.javarebel.integration.support.JavassistClassBytecodeProcessor.process(SourceFile:78)
at com.zeroturnaround.javarebel.tt.a(SourceFile:376)
at com.zeroturnaround.javarebel.tt.a(SourceFile:365)
at com.zeroturnaround.javarebel.tt.a(SourceFile:322)
at com.zeroturnaround.javarebel.SDKIntegrationImpl.runBytecodeProcessors(SourceFile:34)
at com.zeroturnaround.javarebel.rh.transform(SourceFile:106)
at java.lang.ClassLoader.defineClass(ClassLoader.java)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2888)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1172)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1680)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1558)
at org.springframework.context.annotation.ClassPathScanningCandidateComponentProvider.<init>(ClassPathScanningCandidateComponentProvider.java:81)
at org.springframework.context.annotation.ClassPathBeanDefinitionScanner.<init>(ClassPathBeanDefinitionScanner.java:136)
at org.springframework.web.context.support.AnnotationConfigWebApplicationContext.getClassPathBeanDefinitionScanner(AnnotationConfigWebApplicationContext.java:276)
at org.springframework.web.context.support.AnnotationConfigWebApplicationContext.loadBeanDefinitions(AnnotationConfigWebApplicationContext.java:190)
at org.springframework.context.support.AbstractRefreshableApplicationContext.__refreshBeanFactory(AbstractRefreshableApplicationContext.java:129)
at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java)
at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:609)
at org.springframework.context.support.AbstractApplicationContext.__refresh(AbstractApplicationContext.java:510)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java)
at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:444)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:326)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:107)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4797)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5291)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:748)
Caused by: org.zeroturnaround.bundled.javassist.NotFoundException: org.springframework.core.type.classreading.MetadataReaderFactory
at org.zeroturnaround.bundled.javassist.CtClassType.getClassFile3(SourceFile:201)
... 60 more
If I unused the JRebel, the error is gone...

Using Tomcat older than 7.0.70? Version 7.0.12 of JRebel was released that should fix these errors, so try updating your JRebel for Eclipse plugin.

Related

org.springframework.boot.SpringApplication Application startup failed:java.lang.IllegalArgumentException:object is not an instance of declaring class

I'm getting below exception while deploying spring boot application in WildFly14. But same is deployed fine in WildFly10.
spring boot version is 1.5.18
have the same issue with spring 2x as well.
The application I'm deploying is cas overly downloaded from https://github.com/apereo/cas-overlay-template/tree/5.3
20:04:32,506 DEBUG [org.springframework.jndi.JndiPropertySource] (ServerService Thread Pool -- 213) JNDI lookup for name [banner.location] threw NamingException with message: banner.location -- service jboss.naming.context.java."banner.location". Returning null.
20:04:32,506 DEBUG [org.springframework.core.env.PropertySourcesPropertyResolver] (ServerService Thread Pool -- 213) Could not find key 'banner.location' in any property source
20:04:32,522 DEBUG [org.springframework.boot.logging.ClasspathLoggingApplicationListener] (ServerService Thread Pool -- 213) Application failed to start with classpath: unknown
20:04:32,522 ERROR [org.springframework.boot.SpringApplication] (ServerService Thread Pool -- 213) Application startup failed: java.lang.IllegalArgumentException: object is not an instance of declaring class
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.springframework.core.io.VfsUtils.invokeVfsMethod(VfsUtils.java:100)
at org.springframework.core.io.VfsUtils.getFile(VfsUtils.java:172)
at org.springframework.core.io.VfsResource.getFile(VfsResource.java:95)
at org.apereo.cas.util.CasVersion.getDateTime(CasVersion.java:59)
at org.apereo.cas.util.SystemUtils.getSystemInfo(SystemUtils.java:50)
at org.apereo.cas.util.spring.boot.AbstractCasBanner.collectEnvironmentInfo(AbstractCasBanner.java:63)
at org.apereo.cas.util.spring.boot.AbstractCasBanner.printBanner(AbstractCasBanner.java:37)
at org.springframework.boot.SpringApplicationBannerPrinter.print(SpringApplicationBannerPrinter.java:71)
at org.springframework.boot.SpringApplication.printBanner(SpringApplication.java:505)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:298)
at org.springframework.boot.web.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:156)
at org.springframework.boot.web.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:136)
at org.springframework.boot.web.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:91)
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:169)
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:203)
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:185)
at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:42)
at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)
at org.wildfly.extension.undertow.security.SecurityContextThreadSetupAction.lambda$create$0(SecurityContextThreadSetupAction.java:105)
at org.wildfly.extension.undertow.security.SecurityContextThreadSetupAction$$Lambda$658/1543581401.call(Unknown Source)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1502)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction$$Lambda$659/1515086559.call(Unknown Source)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1502)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction$$Lambda$659/1515086559.call(Unknown Source)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1502)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction$$Lambda$659/1515086559.call(Unknown Source)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1502)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction$$Lambda$659/1515086559.call(Unknown Source)
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:250)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.startContext(UndertowDeploymentService.java:96)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:78)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1985)
at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1487)
at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1378)
at java.lang.Thread.run(Thread.java:745)
at org.jboss.threads.JBossThread.run(JBossThread.java:485)
20:04:32,522 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool -- 213) MSC000001: Failed to start service jboss.deployment.unit."cas.war".undertow-deployment: org.jboss.msc.service.StartException in service jboss.deployment.unit."cas.war".undertow-deployment: java.lang.RuntimeException: java.lang.IllegalArgumentException: object is not an instance of declaring class
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:81)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1985)
at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1487)
at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1378)
at java.lang.Thread.run(Thread.java:745)
at org.jboss.threads.JBossThread.run(JBossThread.java:485)
Caused by: java.lang.RuntimeException: java.lang.IllegalArgumentException: object is not an instance of declaring class
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:252)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.startContext(UndertowDeploymentService.java:96)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:78)
... 8 more
Caused by: java.lang.IllegalArgumentException: object is not an instance of declaring class
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.springframework.core.io.VfsUtils.invokeVfsMethod(VfsUtils.java:100)
at org.springframework.core.io.VfsUtils.getFile(VfsUtils.java:172)
at org.springframework.core.io.VfsResource.getFile(VfsResource.java:95)
at org.apereo.cas.util.CasVersion.getDateTime(CasVersion.java:59)
at org.apereo.cas.util.SystemUtils.getSystemInfo(SystemUtils.java:50)
at org.apereo.cas.util.spring.boot.AbstractCasBanner.collectEnvironmentInfo(AbstractCasBanner.java:63)
at org.apereo.cas.util.spring.boot.AbstractCasBanner.printBanner(AbstractCasBanner.java:37)
at org.springframework.boot.SpringApplicationBannerPrinter.print(SpringApplicationBannerPrinter.java:71)
at org.springframework.boot.SpringApplication.printBanner(SpringApplication.java:505)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:298)
at org.springframework.boot.web.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:156)
at org.springframework.boot.web.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:136)
at org.springframework.boot.web.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:91)
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:169)
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:203)
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:185)
at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:42)
at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)
at org.wildfly.extension.undertow.security.SecurityContextThreadSetupAction.lambda$create$0(SecurityContextThreadSetupAction.java:105)
at org.wildfly.extension.undertow.security.SecurityContextThreadSetupAction$$Lambda$658/1543581401.call(Unknown Source)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1502)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction$$Lambda$659/1515086559.call(Unknown Source)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1502)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction$$Lambda$659/1515086559.call(Unknown Source)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1502)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction$$Lambda$659/1515086559.call(Unknown Source)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1502)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction$$Lambda$659/1515086559.call(Unknown Source)
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:250)
... 10 more
20:04:32,523 ERROR [org.jboss.as.controller.management-operation] (DeploymentScanner-threads - 2) WFLYCTL0013: Operation ("full-replace-deployment") failed - address: ([]) - failure description: {"WFLYCTL0080: Failed services" => {"jboss.deployment.unit.\"cas.war\".undertow-deployment" => "java.lang.RuntimeException: java.lang.IllegalArgumentException: object is not an instance of declaring class
Caused by: java.lang.RuntimeException: java.lang.IllegalArgumentException: object is not an instance of declaring class
Caused by: java.lang.IllegalArgumentException: object is not an instance of declaring class"}}

Migration from Spring 3.1.9 to Spring 4.3.9

I am doing a migration
Java7 to Java8
Jboss AS 7.1.1Final to Wildfly 10
Spring 3.1.9 to Spring 4.3.9
All the compilation error has been fixed . At runtime , I am getting below exception....
Can anybody help me on this ?
jboss.undertow.deployment.default-server.default-host./test: org.jboss.msc.service.StartException in service jboss.undertow.deployment.default-server.default-host./test## Heading ##: java.lang.RuntimeException: java.lang.NullPointerException
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:85)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:748)
at org.jboss.threads.JBossThread.run(JBossThread.java:320)
Caused by: java.lang.RuntimeException: java.lang.NullPointerException
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:236)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.startContext(UndertowDeploymentService.java:100)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:82)
... 6 more
Caused by: java.lang.NullPointerException
at org.springframework.core.io.AbstractResource.hashCode(AbstractResource.java:216)
at java.util.HashMap.hash(HashMap.java:338)
at java.util.LinkedHashMap.get(LinkedHashMap.java:440)
at org.springframework.core.type.classreading.CachingMetadataReaderFactory.getMetadataReader(CachingMetadataReaderFactory.java:100)
at org.springframework.core.type.classreading.SimpleMetadataReaderFactory.getMetadataReader(SimpleMetadataReaderFactory.java:93)
at org.springframework.context.annotation.ConfigurationClassUtils.checkConfigurationClassCandidate(ConfigurationClassUtils.java:100)
at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:269)
at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:228)
at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:270)
at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:93)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:687)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:525)
at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:443)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:325)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:107)
at io.undertow.servlet.core.ApplicationListeners.contextInitialized(ApplicationListeners.java:187)
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:200)
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:171)

Hibernate 5 second level cache and hazelcast

I am using hibernate 5.0.5.Final and hazelcast 3.6-EA by:
com.hazelcast:hazelcast-all:3.6-EA2.jar
org.hibernate.javax.persistence:hibernate-jpa-2.1-api:1.0.0.Final.jar
org.hibernate:hibernate-entitymanager:5.0.5.Final.jar
org.hibernate:hibernate-core:5.0.5.Final.jar
org.hibernate:hibernate-java8:5.0.5.Final.jar
I have configured hibernate to use second level cache by properties below:
properties.setProperty("hibernate.cache.use_second_level_cache", "true");
properties.setProperty("hibernate.cache.use_query_cache", "true");
properties.setProperty("hibernate.cache.region.factory_class", "com.hazelcast.hibernate.HazelcastCacheRegionFactory");
//properties.setProperty("hibernate.cache.region.factory_class", "com.hazelcast.hibernate.HazelcastLocalCacheRegionFactory");
properties.setProperty("hibernate.cache.hazelcast.use_lite_member", "true");
properties.setProperty("hibernate.cache.use_minimal_puts", "true");
During application deploy error occurs:
...
Caused by: org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.cache.spi.RegionFactory]
at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService(AbstractServiceRegistryImpl.java:244)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:208)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:189)
at org.hibernate.boot.internal.MetadataBuilderImpl$MetadataBuildingOptionsImpl.<init>(MetadataBuilderImpl.java:663)
at org.hibernate.boot.internal.MetadataBuilderImpl.<init>(MetadataBuilderImpl.java:127)
at org.hibernate.boot.MetadataSources.getMetadataBuilder(MetadataSources.java:135)
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.<init>(EntityManagerFactoryBuilderImpl.java:180)
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.<init>(EntityManagerFactoryBuilderImpl.java:144)
at org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider$1.<init>(SpringHibernateJpaPersistenceProvider.java:49)
at org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider.createContainerEntityManagerFactory(SpringHibernateJpaPersistenceProvider.java:49)
at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:343)
at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:318)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1633)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1570)
... 58 more
Caused by: org.hibernate.HibernateException: could not instantiate RegionFactory [com.hazelcast.hibernate.HazelcastCacheRegionFactory]
at org.hibernate.cache.internal.RegionFactoryInitiator.initiateService(RegionFactoryInitiator.java:84)
at org.hibernate.cache.internal.RegionFactoryInitiator.initiateService(RegionFactoryInitiator.java:29)
at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.initiateService(StandardServiceRegistryImpl.java:88)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService(AbstractServiceRegistryImpl.java:234)
... 71 more
Caused by: org.hibernate.boot.registry.selector.spi.StrategySelectionException: Unable to resolve name [com.hazelcast.hibernate.HazelcastCacheRegionFactory] as strategy [org.hibernate.cache.spi.RegionFactory]
at org.hibernate.boot.registry.selector.internal.StrategySelectorImpl.selectStrategyImplementor(StrategySelectorImpl.java:113)
at org.hibernate.cache.internal.RegionFactoryInitiator.initiateService(RegionFactoryInitiator.java:71)
... 74 more
After removing spring boot from project, stacktrace change a bit:
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1574)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:539)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:476)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:303)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:299)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)
at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:956)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:747)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:480)
at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:403)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:306)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:106)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4738)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5181)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:725)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:701)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717)
at org.apache.catalina.startup.HostConfig.manageApp(HostConfig.java:1678)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801)
at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:463)
at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:413)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801)
at javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1466)
at javax.management.remote.rmi.RMIConnectionImpl.access$300(RMIConnectionImpl.java:76)
at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1307)
at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1399)
at javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:828)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:323)
at sun.rmi.transport.Transport$1.run(Transport.java:200)
at sun.rmi.transport.Transport$1.run(Transport.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:196)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$241(TCPTransport.java:683)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler$$Lambda$1/495932726.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:682)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.cache.spi.RegionFactory]
at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService(AbstractServiceRegistryImpl.java:244)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:208)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:189)
at org.hibernate.boot.internal.MetadataBuilderImpl$MetadataBuildingOptionsImpl.<init>(MetadataBuilderImpl.java:663)
at org.hibernate.boot.internal.MetadataBuilderImpl.<init>(MetadataBuilderImpl.java:127)
at org.hibernate.boot.MetadataSources.getMetadataBuilder(MetadataSources.java:135)
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.<init>(EntityManagerFactoryBuilderImpl.java:180)
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.<init>(EntityManagerFactoryBuilderImpl.java:144)
at org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider$1.<init>(SpringHibernateJpaPersistenceProvider.java:49)
at org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider.createContainerEntityManagerFactory(SpringHibernateJpaPersistenceProvider.java:49)
at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:343)
at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:318)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1633)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1570)
... 58 more
Caused by: org.hibernate.HibernateException: could not instantiate RegionFactory [com.hazelcast.hibernate.HazelcastCacheRegionFactory]
at org.hibernate.cache.internal.RegionFactoryInitiator.initiateService(RegionFactoryInitiator.java:84)
at org.hibernate.cache.internal.RegionFactoryInitiator.initiateService(RegionFactoryInitiator.java:29)
at org.hibernate.boot.registry.internal.StandardServiceRegistryImpl.initiateService(StandardServiceRegistryImpl.java:88)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.createService(AbstractServiceRegistryImpl.java:234)
... 71 more
Caused by: org.hibernate.boot.registry.selector.spi.StrategySelectionException: Unable to resolve name [com.hazelcast.hibernate.HazelcastCacheRegionFactory] as strategy [org.hibernate.cache.spi.RegionFactory]
at org.hibernate.boot.registry.selector.internal.StrategySelectorImpl.selectStrategyImplementor(StrategySelectorImpl.java:113)
at org.hibernate.cache.internal.RegionFactoryInitiator.initiateService(RegionFactoryInitiator.java:71)
... 74 more
How to solve this problem?
Hazelcast does not support officially Hibernate 5 in 3.6-EA2 release. There is a pending PR for it that you can follow up the progress.
Issue: https://github.com/hazelcast/hazelcast/issues/5633
Related PR: https://github.com/hazelcast/hazelcast/pull/7021

NoClassDefFoundException in spring project

I am getting the NoClassDefFoundException, I tried clean project, restarted in eclipse,
and i have the following jar files in the class path. But still i am getting the error
can anyone please tell what i am doing wrong?
Thanks in advance.
commons-logging-1.1.2.jar
jstl-1.2.jar
log4j-1.2.16.jar
spring-aspects-3.2.5.RELEASE.jar
spring-beans-3.2.5.RELEASE.jar
spring-context-3.2.5.RELEASE.jar
spring-core-3.2.5.RELEASE.jar
spring-expression-3.2.5.RELEASE.jar
spring-web-3.2.5.RELEASE.jar
spring-webmvc-3.2.5.RELEASE.jar
servlet-api-2.5.jar
java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/FPWSMVCXML]]
at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:222)
at java.util.concurrent.FutureTask.get(FutureTask.java:83)
at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1128)
at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:782)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1566)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1556)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
at java.lang.Thread.run(Thread.java:662)
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/FPWSMVCXML]]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
... 7 more
Caused by: java.lang.NoClassDefFoundError: org/springframework/web/context/support/ServletRequestHandledEvent
at java.lang.Class.getDeclaredFields0(Native Method)
at java.lang.Class.privateGetDeclaredFields(Class.java:2300)
at java.lang.Class.getDeclaredFields(Class.java:1745)
at org.apache.catalina.startup.WebAnnotationSet.getDeclaredFields(WebAnnotationSet.java:452)
at org.apache.catalina.startup.WebAnnotationSet.loadFieldsAnnotation(WebAnnotationSet.java:257)
at org.apache.catalina.startup.WebAnnotationSet.loadApplicationServletAnnotations(WebAnnotationSet.java:136)
at org.apache.catalina.startup.WebAnnotationSet.loadApplicationAnnotations(WebAnnotationSet.java:66)
at org.apache.catalina.startup.ContextConfig.applicationAnnotationsConfig(ContextConfig.java:381)
at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:858)
at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:345)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5161)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 7 more
Caused by: java.lang.ClassNotFoundException: org.springframework.web.context.support.ServletRequestHandledEvent
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1711)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1556)
... 21 more

getting java.lang.ClassNotFoundException for MultitenantAddressingBasedDispatcher

I am getting class not found exception for one of the jars from wso2 app server 5.1.0.
I have copied here the stack trace as below:
[2013-09-16 14:04:17,562] INFO {org.apache.axis2.deployment.AxisConfigBuilder} - org.wso2.carbon.core.deployment.DeploymentInterceptor
[2013-09-16 14:04:17,578] FATAL {org.wso2.carbon.core.init.CarbonServerManager} - WSO2 Carbon initialization Failed
org.apache.axis2.AxisFault: Exception occured while loading the Axis configuration from C:\WSO2AS\WSO2AS~1.0\bin\../repository/conf/axis2/axis2.xml
at org.wso2.carbon.core.CarbonAxisConfigurator.getAxisConfiguration(CarbonAxisConfigurator.java:190)
at org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:64)
at org.wso2.carbon.core.CarbonConfigurationContextFactory.createNewConfigurationContext(CarbonConfigurationContextFactory.java:65)
at org.wso2.carbon.core.init.CarbonServerManager.initializeCarbon(CarbonServerManager.java:398)
at org.wso2.carbon.core.init.CarbonServerManager.start(CarbonServerManager.java:219)
at org.wso2.carbon.core.internal.CarbonCoreServiceComponent.activate(CarbonCoreServiceComponent.java:69)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:260)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:146)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:347)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:620)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:197)
at org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:343)
at org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222)
at org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
at org.eclipse.equinox.http.servlet.internal.Activator.registerHttpService(Activator.java:81)
at org.eclipse.equinox.http.servlet.internal.Activator.addProxyServlet(Activator.java:60)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.init(ProxyServlet.java:40)
at org.wso2.carbon.tomcat.ext.servlet.DelegationServlet.init(DelegationServlet.java:38)
at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1267)
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1186)
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1081)
at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5027)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5314)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:724)
Caused by: org.apache.axis2.deployment.DeploymentException: org.wso2.carbon.core.multitenancy.MultitenantAddressingBasedDispatcher
at org.apache.axis2.deployment.util.Utils.loadHandler(Utils.java:149)
at org.apache.axis2.deployment.AxisConfigBuilder.processPhaseList(AxisConfigBuilder.java:549)
at org.apache.axis2.deployment.AxisConfigBuilder.processPhaseOrders(AxisConfigBuilder.java:580)
at org.apache.axis2.deployment.AxisConfigBuilder.populateConfig(AxisConfigBuilder.java:150)
at org.wso2.carbon.core.CarbonAxisConfigurator.populateAxisConfiguration(CarbonAxisConfigurator.java:308)
at org.wso2.carbon.core.CarbonAxisConfigurator.getAxisConfiguration(CarbonAxisConfigurator.java:188)
... 42 more
Caused by: java.lang.ClassNotFoundException: org.wso2.carbon.core.multitenancy.MultitenantAddressingBasedDispatcher
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:501)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:421)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:412)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:190)
at org.apache.axis2.util.Loader.loadClass(Loader.java:261)
at org.apache.axis2.util.Loader.loadClass(Loader.java:229)
at org.apache.axis2.deployment.util.Utils.loadHandler(Utils.java:116)
... 47 more
Due to this exception described above, the UI of Application Server fails to come up.
The bundle status information is as below:
227 ACTIVE org.wso2.carbon.caching.stub_4.1.0
228 ACTIVE org.wso2.carbon.caching.ui_4.1.0
229 ACTIVE org.wso2.carbon.captcha.mgt_4.1.0
230 ACTIVE org.wso2.carbon.cluster.mgt.core_4.1.0
231 ACTIVE org.wso2.carbon.coordination.common_4.1.0
232 ACTIVE org.wso2.carbon.coordination.core_4.1.0
233 ACTIVE org.wso2.carbon.core_4.1.0
234 ACTIVE org.wso2.carbon.core.bootup.validator_4.1.0
235 ACTIVE org.wso2.carbon.core.common_4.1.0
236 ACTIVE org.wso2.carbon.core.commons.stub_4.1.0
237 ACTIVE org.wso2.carbon.core.services_4.1.0
After little search I found out that org.wso2.carbon.core_4.1.0 contains the class
org.wso2.carbon.core.multitenancy.MultitenantAddressingBasedDispatcher.
I am still not clear about that class's visibility to classloader even if its bundle is ACTIVE..
Any guideline on this will be very helpful..
Thanks & regards,Parimal
It seems to be a problem with httpcore-nio version and the mentioned revision change is not there in the pack.

Resources