Olá pessoal, estou realizei um upgrade no meu back-end e gerei o war pelo maven para um servidor tomcat 9.0.67, porém o meu serviço
nao está subindo está me retornando o erro abaixo porém está declarado certinho minha controller, localmente o serviço dentro da ide
do Spring Tool Suite 4 funciona perfeitamente ja fiz todos tipos de consulta inser funciona tranquilo o problema está
quando coloco em um servidor tomcat, alguem poderia me ajudar ?
SEGUE ABAIXO O LOGO DO TOMCAT
###############################################################################. ____ _ __ _ _
/\ / ’ __ _ () __ __ _ \ \ \
( ( )__ | '_ | '| | ’ / ` | \ \ \
\/ )| |)| | | | | || (| | ) ) ) )
’ || .__|| ||| |_, | / / / /
=========||==============|/=////
:: Spring Boot :: (v2.4.4)2022-09-28 09:52:38.205 INFO 38053 — [alina-utility-1] b.c.portalgrupojcr.PortaljcrApplication : Starting PortaljcrApplication v1.0 using Java 1.8.0_345 portalgrupojcr-1.0/WEB-INF/classes started by root in /home/admin/Downloads/apache-tomcat-9.0.67/bin)
2022-09-28 09:52:38.211 INFO 38053 — [alina-utility-1] b.c.portalgrupojcr.PortaljcrApplication : No active profile set, falling back to default profiles:
2022-09-28 09:52:39.827 INFO 38053 — [alina-utility-1] .s.d.r.c.RepositoryConfigurationDelegate : Bootstrapping Spring Data JPA repositories in DEFAULT mo
2022-09-28 09:52:40.300 INFO 38053 — [alina-utility-1] .s.d.r.c.RepositoryConfigurationDelegate : Finished Spring Data repository scanning in 455 ms. Foun
2022-09-28 09:52:41.106 INFO 38053 — [alina-utility-1] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.security.access.expression.metk.security.access.expression.method.DefaultMethodSecurityExpressionHandler] is not eligible for getting processed by all BeanPostProcessors (for example: not
2022-09-28 09:52:41.117 INFO 38053 — [alina-utility-1] trationDelegate$BeanPostProcessorChecker : Bean ‘methodSecurityMetadataSource’ of type [org.springfligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2022-09-28 09:52:41.205 INFO 38053 — [alina-utility-1] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in
2022-09-28 09:52:41.944 INFO 38053 — [alina-utility-1] o.hibernate.jpa.internal.util.LogHelper : HHH000204: Processing PersistenceUnitInfo [name: default
2022-09-28 09:52:42.087 INFO 38053 — [alina-utility-1] org.hibernate.Version : HHH000412: Hibernate ORM core version 5.4.29.Final
2022-09-28 09:52:42.376 INFO 38053 — [alina-utility-1] o.hibernate.annotations.common.Version : HCANN000001: Hibernate Commons Annotations {5.1.2.Final}
2022-09-28 09:52:42.624 INFO 38053 — [alina-utility-1] com.zaxxer.hikari.HikariDataSource : HikariPool-5 - Starting…
2022-09-28 09:52:42.916 INFO 38053 — [alina-utility-1] com.zaxxer.hikari.HikariDataSource : HikariPool-5 - Start completed.
2022-09-28 09:52:42.982 INFO 38053 — [alina-utility-1] org.hibernate.dialect.Dialect : HHH000400: Using dialect: org.hibernate.dialect.MySQL8Di
2022-09-28 09:52:45.148 INFO 38053 — [alina-utility-1] o.h.e.t.j.p.i.JtaPlatformInitiator : HHH000490: Using JtaPlatform implementation: [org.hibern
2022-09-28 09:52:45.167 INFO 38053 — [alina-utility-1] j.LocalContainerEntityManagerFactoryBean : Initialized JPA EntityManagerFactory for persistence uni
2022-09-28 09:52:46.170 WARN 38053 — [alina-utility-1] JpaBaseConfiguration$JpaWebConfiguration : spring.jpa.open-in-view is enabled by default. Thereforespring.jpa.open-in-view to disable this warning
2022-09-28 09:52:46.656 WARN 38053 — [alina-utility-1] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - can: Error creating bean with name ‘governoController’: Lookup method resolution failed; nested exception is java.lang.IllegalStateException: Failed to introsp ClassLoader [ParallelWebappClassLoader
context: portalgrupojcr-1.0
delegate: false
----------> Parent Classloader:
java.net.URLClassLoader@31221be2
]
2022-09-28 09:52:46.658 INFO 38053 — [alina-utility-1] j.LocalContainerEntityManagerFactoryBean : Closing JPA EntityManagerFactory for persistence unit 'd
2022-09-28 09:52:46.661 INFO 38053 — [alina-utility-1] com.zaxxer.hikari.HikariDataSource : HikariPool-5 - Shutdown initiated…
2022-09-28 09:52:46.688 INFO 38053 — [alina-utility-1] com.zaxxer.hikari.HikariDataSource : HikariPool-5 - Shutdown completed.
2022-09-28 09:52:46.701 INFO 38053 — [alina-utility-1] ConditionEvaluationReportLoggingListener :Error starting ApplicationContext. To display the conditions report re-run your application with ‘debug’ enabled.
2022-09-28 09:52:46.756 ERROR 38053 — [alina-utility-1] o.s.boot.SpringApplication : Application run failedorg.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘governoController’: Lookup method resolution failed; nested exceptionupojcr.governeapps2.controller.GovernoController] from ClassLoader [ParallelWebappClassLoader
context: portalgrupojcr-1.0
delegate: false
----------> Parent Classloader:
java.net.URLClassLoader@31221be2
]
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors(AutowiredAnnotationBeanPostProces
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineConstructorsFromBeanPostProcessors(AbstractAutowireCapableBe
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1201) ~[sp
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:564) ~[spring-be
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524) ~[spring-bean
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335) ~[spring-beans-5.3.5.jar:5.3.5]
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234) ~[spring-beans-5.3.5.ja
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333) ~[spring-beans-5.3.5.jar:5.3.5]
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208) ~[spring-beans-5.3.5.jar:5.3.5]
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:944) ~[spring-beans-
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:918) ~[spring-conte
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:583) ~[spring-context-5.3.5.jar:5.3.5]
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:144) ~[spring-boot
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:769) ~[spring-boot-2.4.4.jar:2.4.4]
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:761) ~[spring-boot-2.4.4.jar:2.4.4]
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:426) ~[spring-boot-2.4.4.jar:2.4.4]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:326) ~[spring-boot-2.4.4.jar:2.4.4]
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:173) [spring-boot-2.4.4.jar:2.4.4]
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:153) [spr
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:95) [spring-boot-2.4.4.jar:2
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174) [spring-web-5.3.5.jar:5.3.5]
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5220) [catalina.jar:9.0.67]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) [catalina.jar:9.0.67]
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:726) [catalina.jar:9.0.67]
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:698) [catalina.jar:9.0.67]
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:696) [catalina.jar:9.0.67]
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1024) [catalina.jar:9.0.67]
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1911) [catalina.jar:9.0.67]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_345]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_345]
at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) [tomcat-util.jar:9.0.67]
at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:112) [na:1.8.0_345]
at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:825) [catalina.jar:9.0.67]
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:475) [catalina.jar:9.0.67]
at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1667) [catalina.jar:9.0.67]
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:315) [catalina.jar:9.0.67]
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123) [catalina.jar:9.0.67]
at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1162) [catalina.jar:9.0.67]
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1365) [catalina.jar:9.0.67]
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1369) [catalina.jar:9.0.67]
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1347) [catalina.jar:9.0.67]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_345]
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [na:1.8.0_345]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [na:1.8.0_345]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [na:1.8.0_345]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [na:1.8.0_345]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [na:1.8.0_345]
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:9.0.67]
at java.lang.Thread.run(Thread.java:750) [na:1.8.0_345]
Caused by: java.lang.IllegalStateException: Failed to introspect Class [br.com.portalgrupojcr.governeapps2.controller.GovernoController] from ClassLoader [Pa
context: portalgrupojcr-1.0
delegate: false
----------> Parent Classloader:
java.net.URLClassLoader@31221be2
]
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:481) ~[spring-core-5.3.5.jar:5.3.5]
at org.springframework.util.ReflectionUtils.doWithLocalMethods(ReflectionUtils.java:321) ~[spring-core-5.3.5.jar:5.3.5]
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors(AutowiredAnnotationBeanPostProces
… 48 common frames omitted
Caused by: java.lang.NoClassDefFoundError: org/springframework/boot/configurationprocessor/json/JSONException
at java.lang.Class.getDeclaredMethods0(Native Method) ~[na:1.8.0_345]
at java.lang.Class.privateGetDeclaredMethods(Class.java:2701) ~[na:1.8.0_345]
at java.lang.Class.getDeclaredMethods(Class.java:1975) ~[na:1.8.0_345]
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:463) ~[spring-core-5.3.5.jar:5.3.5]
… 50 common frames omitted
Caused by: java.lang.ClassNotFoundException: org.springframework.boot.configurationprocessor.json.JSONException
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1412) ~[catalina.jar:9.0.67]
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1220) ~[catalina.jar:9.0.67]
… 54 common frames omitted28-Sep-2022 09:52:46.757 GRAVE [Catalina-utility-1] org.apache.catalina.startup.HostConfig.deployWAR Error deploying web application archive [/home/admin/Dow
java.lang.IllegalStateException: Error starting child
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:729)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:698)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:696)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1024)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1911)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:112)
at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:825)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:475)
at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1667)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:315)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1162)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1365)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1369)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1347)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Thread.java:750)
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/porta
at org.apache.catalina.util.LifecycleBase.handleSubClassException(LifecycleBase.java:440)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:198)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:726)
… 25 more
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘governoController’: Lookup method resolution failess [br.com.portalgrupojcr.governeapps2.controller.GovernoController] from ClassLoader [ParallelWebappClassLoader
context: portalgrupojcr-1.0
delegate: false
----------> Parent Classloader:
java.net.URLClassLoader@31221be2
]
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors(AutowiredAnnotationBeanPo
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineConstructorsFromBeanPostProcessors(AbstractAutowireC
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:12
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:564)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:944)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:918)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:583)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:144)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:769)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:761)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:426)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:326)
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:173)
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:1
at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:95)
at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5220)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
… 26 more
Caused by: java.lang.IllegalStateException: Failed to introspect Class [br.com.portalgrupojcr.governeapps2.controller.GovernoController] from ClassLo
context: portalgrupojcr-1.0
delegate: false
----------> Parent Classloader:
java.net.URLClassLoader@31221be2
]
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:481)
at org.springframework.util.ReflectionUtils.doWithLocalMethods(ReflectionUtils.java:321)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors(AutowiredAnnotationBeanPo
… 48 more
Caused by: java.lang.NoClassDefFoundError: org/springframework/boot/configurationprocessor/json/JSONException
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
at java.lang.Class.getDeclaredMethods(Class.java:1975)
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:463)
… 50 more
Caused by: java.lang.ClassNotFoundException: org.springframework.boot.configurationprocessor.json.JSONException
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1412)
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1220)
… 54 more
28-Sep-2022 09:52:46.760 INFORMAÇÕES [Catalina-utility-1] org.apache.catalina.startup.HostConfig.deployWAR Deployment of web application archive [/home/admin[22.324] ms
^_ Exception encountered during context initialization - can: Error creating bean with name ‘governoController’: Lookup method resolution failed; nested exception is java.lang.IllegalStateException: Failed to introsp