I have a simple Spring Boot web application.
https://gist.github.com/IvanZelenskyy/90f554276c6b3665f11368c7152ae97e
And I have a Tomcat 8.x and TomEE 7.x servers with default config both.
When I deploy my app (as war) to Tomcat (and also to Glassfish), and it works fine. But when I'm trying to deploy this war to TomEE, I got a lot exception in logs:
07-Sep-2018 14:05:45.627 INFO [localhost-startStop-2] sun.reflect.DelegatingMethodAccessorImpl.invoke Deploying web application archive [/home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1.war]
07-Sep-2018 14:05:45.629 INFO [localhost-startStop-2] org.apache.tomee.catalina.TomcatWebAppBuilder.init ------------------------- localhost -> /demotomee1
07-Sep-2018 14:05:45.633 INFO [localhost-startStop-2] org.apache.openejb.util.JarExtractor.extract Extracting jar: /home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1.war
07-Sep-2018 14:05:45.744 INFO [localhost-startStop-2] org.apache.openejb.util.JarExtractor.extract Extracted path: /home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1
07-Sep-2018 14:05:46.180 INFO [localhost-startStop-2] org.apache.openejb.config.ConfigurationFactory.configureApplication Configuring enterprise application: /home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1
07-Sep-2018 14:05:46.402 INFO [localhost-startStop-2] org.apache.openejb.config.ConfigurationFactory.configureService Configuring Service(id=Default Managed Container, type=Container, provider-id=Default Managed Container)
07-Sep-2018 14:05:46.403 INFO [localhost-startStop-2] org.apache.openejb.config.AutoConfig.createContainer Auto-creating a container for bean demotomee1.Comp1226937296: Container(type=MANAGED, id=Default Managed Container)
07-Sep-2018 14:05:46.403 INFO [localhost-startStop-2] org.apache.openejb.assembler.classic.Assembler.createRecipe Creating Container(id=Default Managed Container)
07-Sep-2018 14:05:46.429 INFO [localhost-startStop-2] org.apache.openejb.core.managed.SimplePassivater.init Using directory /home/ivan/apache-tomee-plume-7.0.5/temp for stateful session passivation
07-Sep-2018 14:05:46.478 INFO [localhost-startStop-2] org.apache.openejb.config.AppInfoBuilder.build Enterprise application "/home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1" loaded.
07-Sep-2018 14:05:46.478 INFO [localhost-startStop-2] org.apache.openejb.assembler.classic.Assembler.createApplication Assembling app: /home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1
14:05:46.915 [localhost-startStop-2] DEBUG org.jboss.logging - Logging Provider: org.jboss.logging.Log4j2LoggerProvider
07-Sep-2018 14:05:46.988 INFO [localhost-startStop-2] org.apache.openejb.assembler.classic.Assembler.destroyApplication Undeploying app: /home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1
07-Sep-2018 14:05:46.993 SEVERE [localhost-startStop-2] sun.reflect.NativeMethodAccessorImpl.invoke ContainerBase.removeChild: destroy:
org.apache.catalina.LifecycleException: An invalid Lifecycle transition was attempted ([before_destroy]) for component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/demotomee1]] in state [STARTING_PREP]
at org.apache.catalina.util.LifecycleBase.invalidTransition(LifecycleBase.java:402)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:856)
at org.apache.tomee.catalina.TomcatWebAppBuilder.undeploy(TomcatWebAppBuilder.java:1651)
at org.apache.tomee.catalina.TomcatWebAppBuilder.undeploy(TomcatWebAppBuilder.java:1631)
at org.apache.tomee.catalina.TomcatWebAppBuilder.undeployWebApps(TomcatWebAppBuilder.java:764)
at org.apache.openejb.assembler.classic.Assembler.destroyApplication(Assembler.java:2374)
at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:1092)
at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:757)
at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1303)
at org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:1125)
at org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:133)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5154)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:754)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
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:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
07-Sep-2018 14:05:47.137 SEVERE [localhost-startStop-2] org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal Unable to deploy collapsed ear in war StandardEngine[Catalina].StandardHost[localhost].StandardContext[/demotomee1]
org.apache.openejb.OpenEJBException: Creating application failed: /home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1: javax.validation.spi.ConfigurationState.getValueExtractors()Ljava/util/Set;
at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:1096)
at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:757)
at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1303)
at org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:1125)
at org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:133)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5154)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:754)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
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:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.NoSuchMethodError: javax.validation.spi.ConfigurationState.getValueExtractors()Ljava/util/Set;
at org.hibernate.validator.internal.engine.ValidatorFactoryImpl.<init>(ValidatorFactoryImpl.java:140)
at org.hibernate.validator.HibernateValidator.buildValidatorFactory(HibernateValidator.java:38)
at org.apache.bval.jsr.ConfigurationImpl.__privileged_doBuildValidatorFactory(ConfigurationImpl.java:332)
at org.apache.bval.jsr.ConfigurationImpl.doBuildValidatorFactory(ConfigurationImpl.java)
at org.apache.bval.jsr.ConfigurationImpl.buildValidatorFactory(ConfigurationImpl.java:324)
at org.apache.openejb.assembler.classic.ValidatorBuilder$OpenEjbConfig.buildValidatorFactory(ValidatorBuilder.java:401)
at org.apache.openejb.assembler.classic.ValidatorBuilder.buildFactory(ValidatorBuilder.java:111)
at org.apache.openejb.assembler.classic.ValidatorBuilder.buildFactory(ValidatorBuilder.java:67)
at org.apache.openejb.assembler.classic.LazyValidatorFactory.ensureDelegate(LazyValidatorFactory.java:54)
at org.apache.openejb.assembler.classic.LazyValidatorFactory.getFactory(LazyValidatorFactory.java:65)
at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:975)
... 17 more
07-Sep-2018 14:05:47.138 SEVERE [localhost-startStop-2] sun.reflect.NativeMethodAccessorImpl.invoke ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/demotomee1]]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:754)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
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:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: org.apache.tomee.catalina.TomEERuntimeException: org.apache.openejb.OpenEJBException: Creating application failed: /home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1: javax.validation.spi.ConfigurationState.getValueExtractors()Ljava/util/Set;
at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1315)
at org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:1125)
at org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:133)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5154)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 10 more
Caused by: org.apache.openejb.OpenEJBException: Creating application failed: /home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1: javax.validation.spi.ConfigurationState.getValueExtractors()Ljava/util/Set;
at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:1096)
at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:757)
at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1303)
... 15 more
Caused by: java.lang.NoSuchMethodError: javax.validation.spi.ConfigurationState.getValueExtractors()Ljava/util/Set;
at org.hibernate.validator.internal.engine.ValidatorFactoryImpl.<init>(ValidatorFactoryImpl.java:140)
at org.hibernate.validator.HibernateValidator.buildValidatorFactory(HibernateValidator.java:38)
at org.apache.bval.jsr.ConfigurationImpl.__privileged_doBuildValidatorFactory(ConfigurationImpl.java:332)
at org.apache.bval.jsr.ConfigurationImpl.doBuildValidatorFactory(ConfigurationImpl.java)
at org.apache.bval.jsr.ConfigurationImpl.buildValidatorFactory(ConfigurationImpl.java:324)
at org.apache.openejb.assembler.classic.ValidatorBuilder$OpenEjbConfig.buildValidatorFactory(ValidatorBuilder.java:401)
at org.apache.openejb.assembler.classic.ValidatorBuilder.buildFactory(ValidatorBuilder.java:111)
at org.apache.openejb.assembler.classic.ValidatorBuilder.buildFactory(ValidatorBuilder.java:67)
at org.apache.openejb.assembler.classic.LazyValidatorFactory.ensureDelegate(LazyValidatorFactory.java:54)
at org.apache.openejb.assembler.classic.LazyValidatorFactory.getFactory(LazyValidatorFactory.java:65)
at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:975)
... 17 more
07-Sep-2018 14:05:47.138 SEVERE [localhost-startStop-2] sun.reflect.NativeMethodAccessorImpl.invoke Error deploying web application archive [/home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1.war]
java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/demotomee1]]
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:758)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
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:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
07-Sep-2018 14:05:47.138 INFO [localhost-startStop-2] sun.reflect.DelegatingMethodAccessorImpl.invoke Deployment of web application archive [/home/ivan/apache-tomee-plume-7.0.5/webapps/demotomee1.war] has finished in [1,511] ms
What can I do to start my app on TomEE?
I had the same problems. I was able to get a working Spring Boot application on TomEE with its dependency and exclusiion of hibernate-validator in pom.xml:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<exclusions>
<exclusion>
<groupId>org.hibernate.validator</groupId>
<artifactId>hibernate-validator</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.tomee</groupId>
<artifactId>apache-tomee</artifactId>
<version>7.X.X</version>
</dependency>
Related
I have multiple Spring Framework enabled projects and try to deploy them into Tomcat.
If I deploy any single one, everything fine.
But if I deploy more than one projects, the deployment will fail from the second one.
Not sure if it caused by Spring or Tomcat. The error info related the Spring framework initialization.
Hope to know if it is a popular one.
Thanks in advance.
Log:
Nov 16, 2017 3:09:01 PM org.apache.catalina.core.StandardContext resourcesStart
Severe: Error starting static Resources
java.lang.IllegalArgumentException: Invalid or unreadable WAR file : error in opening zip file
at org.apache.naming.resources.WARDirContext.setDocBase(WARDirContext.java:136)
at org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:5247)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5436)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:899)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:875)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:652)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1092)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1984)
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:745)
Nov 16, 2017 3:09:01 PM org.apache.catalina.core.ContainerBase addChildInternal
Severe: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/wshermesadminweb]]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:162)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:899)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:875)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:652)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1092)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1984)
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:745)
Caused by: org.apache.catalina.LifecycleException: Error in resourceStart()
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5437)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
... 10 more
Nov 16, 2017 3:09:01 PM org.apache.catalina.startup.HostConfig deployWAR
Severe: Error deploying web application archive C:\Users\chenhang.AUTH\Documents\Tools\apache-tomcat-7.0.77\webapps\wshermesadminweb.war
java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].Standar
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:903)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:875)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:652)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1092)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1984)
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:745)
I try to install Liferay 7 ce ga3 on centos and I get the following error. I installed oracle jdk 8 in centos and extracted the bundle in /opt.
Since I want to connect with oracle 12c I completed the steps in this article: https://www.dontesta.it/en/2016/04/13/liferay-7-ce-how-to-add-support-for-oracle-db/ and I uploaded ojdbc6.jar and liferay-portal-oracledb-support-1.0-SNAPSHOT.jar in $LIFERAY_HOME/$TOMCAT_HOME/lib/ext
Loading file:/opt/liferay-ce-portal-7.0-ga3/portal-ext.properties 13:25:50,890 INFO [localhost-startStop-1][DialectDetector:75] Determine dialect for Oracle 12.1 13:25:51,046 INFO [localhost-startStop-1][DialectDetector:148] Found dialect org.hibernate.dialect.Oracle10gDialect 09-Mar-2017 13:25:51.494 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.listenerStart Exception sending context initialized event to listener instance of class com.liferay.portal.spring.context.PortalContextLoaderListener java.lang.RuntimeException: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'counterHibernateSessionFactory' defined in class path resource [META-INF/hibernate-spring.xml]: Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: com/liferay/portal/dao/db/BaseDB
at com.liferay.portal.spring.context.PortalContextLoaderListener.contextInitialized(PortalContextLoaderListener.java:256)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4812)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5255)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
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.deployDescriptor(HostConfig.java:585)
at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1794)
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:745) Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'counterHibernateSessionFactory' defined in class path resource [META-INF/hibernate-spring.xml]: Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: com/liferay/portal/dao/db/BaseDB
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1572)
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.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:736)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:762)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:480)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:93)
at com.liferay.portal.spring.context.ArrayApplicationContext.<init>(ArrayApplicationContext.java:31)
at com.liferay.portal.spring.context.PortalContextLoaderListener.contextInitialized(PortalContextLoaderListener.java:243)
... 13 more Caused by: java.lang.NoClassDefFoundError: com/liferay/portal/dao/db/BaseDB
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:760)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:467)
at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
at java.net.URLClassLoader$1.run(URLClassLoader.java:368)
at java.net.URLClassLoader$1.run(URLClassLoader.java:362)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:361)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at it.dontesta.labs.liferay.portal.dao.db.OracleDBFactory.doCreate(OracleDBFactory.java:14)
at com.liferay.portal.kernel.dao.db.BaseDBFactory.create(BaseDBFactory.java:39)
at com.liferay.portal.dao.db.DBManagerImpl.getDB(DBManagerImpl.java:117)
at com.liferay.portal.kernel.dao.db.DBManagerUtil.setDB(DBManagerUtil.java:64)
at com.liferay.portal.spring.hibernate.PortalHibernateConfiguration.newConfiguration(PortalHibernateConfiguration.java:140)
at org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(LocalSessionFactoryBean.java:505)
at com.liferay.portal.spring.hibernate.PortalHibernateConfiguration.buildSessionFactory(PortalHibernateConfiguration.java:68)
at org.springframework.orm.hibernate3.AbstractSessionFactoryBean.afterPropertiesSet(AbstractSessionFactoryBean.java:189)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1631)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1568)
... 26 more Caused by: java.lang.ClassNotFoundException: com.liferay.portal.dao.db.BaseDB
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 47 more
09-Mar-2017 13:25:51.499 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal One or more listeners failed to start. Full details will be found in the appropriate container log file 09-Mar-2017 13:25:51.501 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal Context [] startup failed due to previous errors 13:25:51,533 ERROR [localhost-startStop-1][PortalContextLoaderListener:114] java.lang.NullPointerException java.lang.NullPointerException
at com.liferay.portal.kernel.servlet.DirectServletRegistryUtil.clearServlets(DirectServletRegistryUtil.java:27)
at com.liferay.portal.spring.context.PortalContextLoaderListener.contextDestroyed(PortalContextLoaderListener.java:132)
at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:4859)
at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5478)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:224)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:159)
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.deployDescriptor(HostConfig.java:585)
at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1794)
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:745) 13:25:51,540 ERROR [localhost-startStop-1][PortalContextLoaderListener:114] java.lang.NullPointerException java.lang.NullPointerException
at com.liferay.portal.kernel.deploy.hot.HotDeployUtil.reset(HotDeployUtil.java:53)
at com.liferay.portal.spring.context.PortalContextLoaderListener.contextDestroyed(PortalContextLoaderListener.java:139)
at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:4859)
at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5478)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:224)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:159)
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.deployDescriptor(HostConfig.java:585)
at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1794)
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:745) 13:25:51,562 ERROR [localhost-startStop-1][PortalContextLoaderListener:114] java.lang.IllegalStateException: The system has not be activated yet. java.lang.IllegalStateException: The system has not be activated yet.
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.setStartLevel(ModuleContainer.java:1442)
at com.liferay.portal.bootstrap.ModuleFrameworkImpl.stopRuntime(ModuleFrameworkImpl.java:518)
at com.liferay.portal.module.framework.ModuleFrameworkUtilAdapter.stopRuntime(ModuleFrameworkUtilAdapter.java:121)
at com.liferay.portal.spring.context.PortalContextLoaderListener.contextDestroyed(PortalContextLoaderListener.java:146)
at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:4859)
at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5478)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:224)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:159)
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.deployDescriptor(HostConfig.java:585)
at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1794)
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:745) 13:25:51,564 ERROR [localhost-startStop-1][PortalBeanLocatorUtil:109] BeanLocator is null 09-Mar-2017 13:25:51.565 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.listenerStop Exception sending context destroyed event to listener instance of class com.liferay.portal.spring.context.PortalContextLoaderListener com.liferay.portal.kernel.bean.BeanLocatorException: BeanLocator is not set
at com.liferay.portal.kernel.bean.PortalBeanLocatorUtil.locate(PortalBeanLocatorUtil.java:74)
at com.liferay.portal.spring.context.PortalContextLoaderListener.closeDataSource(PortalContextLoaderListener.java:377)
at com.liferay.portal.spring.context.PortalContextLoaderListener.contextDestroyed(PortalContextLoaderListener.java:159)
at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:4859)
at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5478)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:224)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:159)
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.deployDescriptor(HostConfig.java:585)
at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1794)
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:745)
09-Mar-2017 13:25:51.588 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor Deployment of configuration descriptor /opt/liferay-ce-portal-7.0-ga3/tomcat-8.0.32/conf/Catalina/localhost/ROOT.xml has finished in 17,910 ms 09-Mar-2017 13:25:51.596 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8080"] 09-Mar-2017 13:25:51.609 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["ajp-nio-8009"] 09-Mar-2017 13:25:51.611 INFO [main] org.apache.catalina.startup.Catalina.start Server startup in 17981 ms
Any ideas what causes the problem?
Thank you.
It is solved. I placed liferay-portal-oracledb-support-1.0-SNAPSHOT.jar in wrong folder. It should be in $LIFERAY_HOME/$TOMCAT_HOME/webapps/ROOT/WEB-INF/lib.
Thus the installation started.
The code you're linking was built for Liferay 7 CE GA1, and it might need to be adopted to GA3 (read: You shouldn't install GA1). Liferay 7 gets more and more modularized, and it might be that some classes moved from the core to a module, thus breaking classpath dependencies (hopefully while maintaining API compatibility). As the technique to add Oracle-compatibility to Liferay seems quite brute-force (it goes to the global classpath instead of being a module) I can easily imagine this.
Note that I have no access to Oracle, so I can't try out that module. Take my explanations with a grain of salt.
To connect Liferay 7.2 with Oracle 12C I used to do:
ojdbc8.jar - get this from Oracle installation home and into
liferay-ce-portal-7.2.1-ga2\tomcat-9.0.17\lib\ext
liferay-portal-database-all-in-one-support-1.2.1.jar - Download latest jar from Maven Repository (E.g. https://mvnrepository.com/artifact/it.dontesta.labs.liferay.portal.db/liferay-portal-database-all-in-one-support/1.2.1) and put into
\liferay-ce-portal-7.2.1-ga2\tomcat-9.0.17\webapps\ROOT\WEB-INF\lib
It works perfectly.
I have a spring boot gradle project with a server module and I am using the gradle war plugin in my build.gradle file.
https://docs.gradle.org/current/userguide/web_project_tutorial.html
Per this link: https://docs.spring.io/spring-boot/docs/current/reference/html/howto-traditional-deployment.html (80.1)
I am overriding the configure method and I can see that a war file is being built and placed in the server/build/tmp directory.
When the project builds it also creates a empty webapp directory at server/src/main/webapp (this is the default webAppDirName).
http://www.petrikainulainen.net/programming/gradle/getting-started-with-gradle-creating-a-web-application-project/
The war is needed so that our ops guys can run it on an external Tomcat container. However, for convenience, us devs are just building and running with the gradle wrapper > ./gradlew :server:bootRun using the embedded Tomcat container.
My problem is that when we do a bootRun it is looking at the empty webapp folder that gets created during the build process and throwing this error:
2016-02-23 10:51:32.632 INFO 83043 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 22443 (https)
2016-02-23 10:51:32.641 INFO 83043 --- [ main] o.apache.catalina.core.StandardService : Starting service Tomcat
2016-02-23 10:51:32.642 INFO 83043 --- [ main] org.apache.catalina.core.StandardEngine : Starting Servlet Engine: Apache Tomcat/8.0.30
2016-02-23 10:51:32.673 ERROR 83043 --- [cat-startStop-1] org.apache.catalina.core.ContainerBase : A child container failed during start
java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat].StandardHost[localhost].StandardContext[/imageretriever]]
at java.util.concurrent.FutureTask.report(FutureTask.java:122) [na:1.8.0_60]
at java.util.concurrent.FutureTask.get(FutureTask.java:192) [na:1.8.0_60]
at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:916) ~[tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:871) [tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1408) [tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1398) [tomcat-embed-core-8.0.30.jar:8.0.30]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_60]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_60]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_60]
at java.lang.Thread.run(Thread.java:745) [na:1.8.0_60]
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat].StandardHost[localhost].StandardContext[/imageretriever]]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154) [tomcat-embed-core-8.0.30.jar:8.0.30]
... 6 common frames omitted
Caused by: org.apache.catalina.LifecycleException: Failed to start component [org.apache.catalina.webresources.StandardRoot#7f31763e]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154) [tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.c.core.StandardContext.resourcesStart(StandardContext.java:4928) ~[tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5058) ~[tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.0.30.jar:8.0.30]
... 6 common frames omitted
Caused by: java.lang.IllegalArgumentException: The main resource set specified [/Users/carlc/intellij_workspace/image-retriever/src/main/webapp] is not valid
at org.apache.catalina.webresources.StandardRoot.createMainResourceSet(StandardRoot.java:723) ~[tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.webresources.StandardRoot.startInternal(StandardRoot.java:684) ~[tomcat-embed-core-8.0.30.jar:8.0.30]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.0.30.jar:8.0.30]
... 9 common frames omitted
I thought the issue might be tangentially related to this: https://github.com/spring-projects/spring-boot/issues/1313
But I wasn't able to glean any helpful information out of it.
I can think of two solutions: 1) remove the offending webapp folder during the build process 2) Configure bootRun to ignore the webapp folder all together 3) Your suggestions go here _____________ :)
I can post the build.gradle or other code you think relevant upon request. Thanks for any help.
I am trying to deploy a Spring application to server running Apache Tomcat. However, I get this error:
SEVERE: ContainerBase.addChild: start: …
org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/RuralIvrs]]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
…
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:976)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1653)
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:745) Caused by: java.lang.NoSuchMethodError:
javax.servlet.ServletContext.getVirtualServerName()Ljava/lang/String;
at org.apache.tomcat.websocket.server.WsServerContainer.(WsServerContainer.java:147)
at org.apache.tomcat.websocket.server.WsSci.init(WsSci.java:131)
at org.apache.tomcat.websocket.server.WsSci.onStartup(WsSci.java:47)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5423)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 10 more
Jan 21, 2016 12:16:42 PM org.apache.catalina.startup.HostConfig
deployWAR … SEVERE: Error deploying web application archive
/home/ruralivrs/Ruralict/apache-tomcat-7.0.42/webapps/RuralIvrs.war
java.lang.IllegalStateException: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/RuralIvrs]]
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:904)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:976)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1653)
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:745)
I was unable to find a solution after searching for several hours. Since I am quite new to this, any help would be greatly appreciated. Thank you!
You can find similar problem in this blog post.
The solution is probably as simple as adding a tomcat.version property to your Maven project’s pom.xml file
<properties>
<tomcat.version>7.0.67</tomcat.version>
</properties>
The reason is explained inside Spring Boot documentation for embedded-servlet-containers.
Spring Boot defaults to Tomcat 8, so you need to tell Spring Boot that your target is Tomcat 7.
I have upgraded spring boot to 1.3.1.RELEASE and spring framework 4.2.4.RELEASE and i am running into issues. I wasn't given security permission for sun.reflect.annotation in tomcat catalina policy.
Can anyone tell why is spring framework trying scan system jar file/classes for web servlet annotations ? Is there a way in spring boot not to scan system file/classes ?
22-Dec-2015 14:15:41.523 SEVERE [localhost-startStop-1] org.apache.catalina.core.ContainerBase.addChildInternal ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/hccore]]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:725)
at org.apache.catalina.core.ContainerBase.access$000(ContainerBase.java:131)
at org.apache.catalina.core.ContainerBase$PrivilegedAddChild.run(ContainerBase.java:153)
at org.apache.catalina.core.ContainerBase$PrivilegedAddChild.run(ContainerBase.java:143)
at java.security.AccessController.doPrivileged(Native Method)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:699)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:945)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1798)
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:745)
Caused by: java.security.AccessControlException: access denied ("java.lang.RuntimePermission" "accessClassInPackage.sun.reflect.annotation")
at java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
at java.security.AccessController.checkPermission(AccessController.java:884)
at java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
at java.lang.SecurityManager.checkPackageAccess(SecurityManager.java:1564)
at sun.reflect.misc.ReflectUtil.checkPackageAccess(ReflectUtil.java:188)
at sun.reflect.misc.ReflectUtil.checkPackageAccess(ReflectUtil.java:164)
at java.lang.reflect.Proxy.getInvocationHandler(Proxy.java:827)
at org.springframework.core.annotation.AnnotationUtils.synthesizeAnnotation(AnnotationUtils.java:1364)
at org.springframework.core.annotation.AnnotationUtils.findAnnotation(AnnotationUtils.java:685)
at org.springframework.core.annotation.AnnotationUtils.findAnnotation(AnnotationUtils.java:660)
at org.springframework.core.annotation.OrderUtils.getOrder(OrderUtils.java:67)
at org.springframework.core.annotation.OrderUtils.getOrder(OrderUtils.java:56)
at org.springframework.core.annotation.AnnotationAwareOrderComparator.findOrder(AnnotationAwareOrderComparator.java:84)
at org.springframework.core.OrderComparator.getOrder(OrderComparator.java:127)
at org.springframework.core.OrderComparator.getOrder(OrderComparator.java:116)
at org.springframework.core.OrderComparator.doCompare(OrderComparator.java:87)
at org.springframework.core.OrderComparator.compare(OrderComparator.java:73)
at java.util.TimSort.countRunAndMakeAscending(TimSort.java:355)
at java.util.TimSort.sort(TimSort.java:220)
at java.util.Arrays.sort(Arrays.java:1438)
at java.util.List.sort(List.java:478)
at java.util.Collections.sort(Collections.java:175)
at org.springframework.core.annotation.AnnotationAwareOrderComparator.sort(AnnotationAwareOrderComparator.java:116)
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:171)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5170)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 14 more
This is probably related to your tomcat policy file. You can find a description of a similar issue and the solution here. Try to check that you have something like this in your tomcat policy file:
permission java.lang.RuntimePermission "accessClassInPackage.sun.reflect.annotation";
permission java.lang.RuntimePermission "accessClassInPackage.sun.reflect.annotation.*";
permission java.lang.RuntimePermission "accessDeclaredMembers";