繁体   English   中英

无法将camunda-bom添加到springboot项目

[英]Can't add camunda-bom to springboot project

我正在尝试使用springboot创建一个camunda应用程序,但是我需要使用Spin Json Node,当我将依赖项添加到pom.xml时,当我将项目作为Java应用程序运行时会出现此错误:

org.springframework.context.ApplicationContextException:无法启动嵌入式容器。 嵌套的异常是org.springframework.boot.context.embedded.EmbeddedServletContainerException:无法在org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.onRefresh(EmbeddedWebApplicationContext.java:137)〜[spring-boot-1.5.7中启动嵌入式Tomcat。 .RELEASE.jar:1.5.7.RELEASE]在org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:537)〜[spring-context-4.3.11.RELEASE.jar:4.3.11.RELEASE]在org.springframework.boot.SpringApplication处的org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122)〜[spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]。在org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:360)的refresh(SpringApplication.java:693)[spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE] [spring-boot-1.5 .7.RELEASE.jar:1.5.7.RELEASE]位于org.springframework.boot.SpringApplication.run(SpringApplication.java:303)[spring-boot-1.5.7.RELEAS org.springframework.boot.SpringApplication.run(SpringApplication.java:1118)的E.jar:1.5.7.RELEASE] org.springframework的[spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE] .boot.SpringApplication.run(SpringApplication.java:1107)[spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE],位于br.com.ntconsult.camundaProject.app.CamundaSpringbootApplication.main(CamundaSpringbootApplication.java :9)[classes /:na]原因:org.springframework.boot.context.embedded.EmbeddedServletContainerException:无法在org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.initialize(TomcatEmbeddedServletContainer.java: 123)〜[spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]在org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer。(TomcatEmbeddedServletContainer.java:84)〜[spring-boot- 1.5.7.RELEASE.jar:1.5.7.RELEASE],位于org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getTomcatEmbeddedServletContainer(TomcatEm beddedServletContainerFactory.java:554)〜[spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]在org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getEmbeddeddedServletContainer(TomcatEmbeddedServletContainerFactory.java:179)〜 org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.createEmbeddedServletContainer(EmbeddedWebApplicationContext.java:164)的[spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]〜[spring-boot-1.5.7。 RELEASE.jar:1.5.7.RELEASE]位于org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.onRefresh(EmbeddedWebApplicationContext.java:134)〜[spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE ] ...省略了8个共同的框架造成原因:org.apache.catalina.LifecycleException:无法在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167)处启动组件[StandardServer [-1]]〜 [tomcat-embed-core-8.5.20.jar:8.5.20]在org.apache.catalina.startup.Tomcat.start(Tomcat.java:367)〜[tomcat-embed-core-8.5.20.jar: 20年8月5日 ] org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.initialize(TomcatEmbeddedServletContainer.java:99)〜[spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE] ... 13个常见框架省略原因:org.apache.catalina.LifecycleException:无法在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167)处启动组件[StandardService [Tomcat]]〜[tomcat-embed-core-8.5 .20.jar:8.5.20],位于org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:793)〜[tomcat-embed-core-8.5.20.jar:8.5.20],位于org.apache .catalina.util.LifecycleBase.start(LifecycleBase.java:150)〜[tomcat-embed-core-8.5.20.jar:8.5.20] ...省略了15个常见框架造成原因:org.apache.catalina.LifecycleException :无法在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167)〜[tomcat-embed-core-8.5.20.jar:8.5.20]处启动组件[StandardEngine [Tomcat]] .apache.catalina.core.StandardService.startInternal(StandardService.java:422)〜[tomcat-embed-c org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)〜[tomcat-embed-core-8.5.20.jar:8.5.20]中的ore-8.5.20.jar:8.5.20]。 ..省略了17个共同的框架原因:org.apache.catalina.LifecycleException:子容器在org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:947)启动时失败。 org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262)的[8.5.20.jar:8.5.20]〜org的[tomcat-embed-core-8.5.20.jar:8.5.20]。 apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)〜[tomcat-embed-core-8.5.20.jar:8.5.20] ...省略了19个常见框架

如果我从pom.xml中的dependencyManagement中删除camunda-bom,则一切正常,但是我不能使用spin json节点之类的东西。

我在github中创建了一个带有此错误的简单项目: https : //github.com/jradesenv/camunda-springboot

您在GitHub上提供的项目在我看来可以很好地运行,并且可以按预期运行。 您切断了堆栈跟踪的一部分,所以我看不到根本原因。 某些东西阻止了Tomcat的启动-可能是已经使用的端口?

PS:昨天我们发布了即将发布的Spring Boot原型的预览: https : //github.com/camunda/camunda-archetypes/tree/master/camunda-archetype-spring-boot/-可能也是一个很好的起点。

仅供参考,我的控制台(我只是拉出代码并运行它):

 ____                                 _         ____  ____  __  __
/ ___| __ _ _ __ ___  _   _ _ __   __| | __ _  | __ )|  _ \|  \/  |
| |   / _` | '_ ` _ \| | | | '_ \ / _` |/ _` | |  _ \| |_) | |\/| |
| |__| (_| | | | | | | |_| | | | | (_| | (_| | | |_) |  __/| |  | |
\____/\__,_|_| |_| |_|\__,_|_| |_|\__,_|\__,_| |____/|_|   |_|  |_|

  Spring-Boot:  (v1.5.7.RELEASE)
  Camunda BPM: (v7.8.0-alpha6)
  Camunda BPM Spring Boot Starter: (v2.3.0-alpha1)

2017-11-22 09:12:24.931  INFO 13404 --- [           main] b.c.n.c.a.CamundaSpringbootApplication   : Starting CamundaSpringbootApplication on LAPTOP-LFHA6NM6 with PID 13404 (C:\Temp\camunda-springboot-support\target\classes started by ruecker in C:\Temp\camunda-springboot-support)
2017-11-22 09:12:24.954  INFO 13404 --- [           main] b.c.n.c.a.CamundaSpringbootApplication   : No active profile set, falling back to default profiles: default
2017-11-22 09:12:25.052  INFO 13404 --- [           main] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@37918c79: startup date [Wed Nov 22 09:12:25 CET 2017]; root of context hierarchy
2017-11-22 09:12:26.624  INFO 13404 --- [           main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2017-11-22 09:12:27.830  INFO 13404 --- [           main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 8080 (http)
2017-11-22 09:12:27.854  INFO 13404 --- [           main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
2017-11-22 09:12:27.856  INFO 13404 --- [           main] org.apache.catalina.core.StandardEngine  : Starting Servlet Engine: Apache Tomcat/8.5.20
2017-11-22 09:12:28.079  INFO 13404 --- [ost-startStop-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
2017-11-22 09:12:28.080  INFO 13404 --- [ost-startStop-1] o.s.web.context.ContextLoader            : Root WebApplicationContext: initialization completed in 3033 ms
2017-11-22 09:12:28.522  INFO 13404 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean  : Mapping servlet: 'dispatcherServlet' to [/]
2017-11-22 09:12:28.567  INFO 13404 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'characterEncodingFilter' to: [/*]
2017-11-22 09:12:28.568  INFO 13404 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2017-11-22 09:12:28.568  INFO 13404 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2017-11-22 09:12:28.568  INFO 13404 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'requestContextFilter' to: [/*]
2017-11-22 09:12:29.118  INFO 13404 --- [           main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for @ControllerAdvice: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@37918c79: startup date [Wed Nov 22 09:12:25 CET 2017]; root of context hierarchy
2017-11-22 09:12:29.232  INFO 13404 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
2017-11-22 09:12:29.234  INFO 13404 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2017-11-22 09:12:29.264  INFO 13404 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Root mapping to handler of type [class org.springframework.web.servlet.mvc.ParameterizableViewController]
2017-11-22 09:12:29.287  INFO 13404 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-11-22 09:12:29.288  INFO 13404 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-11-22 09:12:29.288  INFO 13404 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/lib/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-11-22 09:12:29.288  INFO 13404 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/api/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-11-22 09:12:29.289  INFO 13404 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/app/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-11-22 09:12:29.359  INFO 13404 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-11-22 09:12:29.870  INFO 13404 --- [           main] org.camunda.bpm.spring.boot              : STARTER-SB040 Setting up jobExecutor with corePoolSize=3, maxPoolSize:10
2017-11-22 09:12:29.891  INFO 13404 --- [           main] o.s.s.concurrent.ThreadPoolTaskExecutor  : Initializing ExecutorService  'camundaTaskExecutor'
2017-11-22 09:12:30.101  INFO 13404 --- [           main] org.camunda.bpm.engine.cfg               : ENGINE-12003 Plugin 'CompositeProcessEnginePlugin[genericPropertiesConfiguration, camundaProcessEngineConfiguration, camundaDatasourceConfiguration, camundaJobConfiguration, camundaHistoryConfiguration, camundaMetricsConfiguration, camundaAuthorizationConfiguration, camundaDeploymentConfiguration, failedJobConfiguration]' activated on process engine 'default'
2017-11-22 09:12:32.841  INFO 13404 --- [           main] org.camunda.bpm.spring.boot              : STARTER-SB021 Auto-Deploying resources: []
2017-11-22 09:12:36.911  INFO 13404 --- [           main] org.camunda.bpm.engine.persistence       : ENGINE-03016 Performing database operation 'create' on component 'engine' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.engine.sql'
2017-11-22 09:12:36.965  INFO 13404 --- [           main] org.camunda.bpm.engine.persistence       : ENGINE-03016 Performing database operation 'create' on component 'history' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.history.sql'
2017-11-22 09:12:36.993  INFO 13404 --- [           main] org.camunda.bpm.engine.persistence       : ENGINE-03016 Performing database operation 'create' on component 'identity' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.identity.sql'
2017-11-22 09:12:37.024  INFO 13404 --- [           main] org.camunda.bpm.engine.persistence       : ENGINE-03016 Performing database operation 'create' on component 'case.engine' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.case.engine.sql'
2017-11-22 09:12:37.037  INFO 13404 --- [           main] org.camunda.bpm.engine.persistence       : ENGINE-03016 Performing database operation 'create' on component 'case.history' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.case.history.sql'
2017-11-22 09:12:37.045  INFO 13404 --- [           main] org.camunda.bpm.engine.persistence       : ENGINE-03016 Performing database operation 'create' on component 'decision.engine' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.decision.engine.sql'
2017-11-22 09:12:37.068  INFO 13404 --- [           main] org.camunda.bpm.engine.persistence       : ENGINE-03016 Performing database operation 'create' on component 'decision.history' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.decision.history.sql'
2017-11-22 09:12:37.159  INFO 13404 --- [           main] org.camunda.bpm.engine.persistence       : ENGINE-03067 No history level property found in database
2017-11-22 09:12:37.159  INFO 13404 --- [           main] org.camunda.bpm.engine.persistence       : ENGINE-03065 Creating historyLevel property in database for level: HistoryLevelFull(name=full, id=3)
2017-11-22 09:12:37.171  INFO 13404 --- [           main] org.camunda.bpm.engine                   : ENGINE-00001 Process Engine default created.
2017-11-22 09:12:37.370  INFO 13404 --- [           main] o.c.b.s.b.s.w.f.LazyInitRegistration     : lazy initialized org.camunda.bpm.spring.boot.starter.webapp.filter.LazyProcessEnginesFilter@4e25e00f
2017-11-22 09:12:37.470  INFO 13404 --- [           main] o.c.b.s.b.s.w.f.LazyInitRegistration     : lazy initialized org.camunda.bpm.spring.boot.starter.webapp.filter.LazySecurityFilter@2097d719
2017-11-22 09:12:37.808  INFO 13404 --- [           main] o.s.j.e.a.AnnotationMBeanExporter        : Registering beans for JMX exposure on startup
2017-11-22 09:12:37.934  INFO 13404 --- [           main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat started on port(s): 8080 (http)
2017-11-22 09:12:37.944  INFO 13404 --- [           main] org.camunda.bpm.engine.jobexecutor       : ENGINE-14014 Starting up the JobExecutor[org.camunda.bpm.engine.spring.components.jobexecutor.SpringJobExecutor].
2017-11-22 09:12:37.947  INFO 13404 --- [           main] b.c.n.c.a.CamundaSpringbootApplication   : Started CamundaSpringbootApplication in 13.493 seconds (JVM running for 14.344)
2017-11-22 09:12:37.949  INFO 13404 --- [ingJobExecutor]] org.camunda.bpm.engine.jobexecutor       : ENGINE-14018 JobExecutor[org.camunda.bpm.engine.spring.components.jobexecutor.SpringJobExecutor] starting to acquire jobs

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM