当前位置: 首页 > 知识库问答 >
问题:

如何使用WebConfigurer.class配置activiti 5.21.0

冀鸿才
2023-03-14

我以前的activiti版本是5.11,现在我正试图将其更新到5.21.0。在前面的配置中,使用restlet servlet。现在我尝试通过webconfigurer.class来配置它。我已经在web.xml中注入了webconfigurer侦听器。但它抛出了一个错误。

web.xml条目

<listener><listener-class>org.activiti.rest.servlet.WebConfigurer</listener-class></listener>
SEVERE: Exception sending context initialized event to listener instance of class org.activiti.rest.servlet.WebConfigurer
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'demoDataConfiguration': Invocation of init method failed; nested exception is java.lang.AbstractMethodError: org.activiti.bpmn.converter.child.BaseChildElementParser.parseChildElement(Ljavax/xml/stream/XMLStreamReader;Lorg/activiti/bpmn/model/BaseElement;Lorg/activiti/bpmn/model/BpmnModel;)V
    at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:136)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:408)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1558)
    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:755)
    at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:757)
    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:480)
    at org.activiti.rest.servlet.WebConfigurer.contextInitialized(WebConfigurer.java:45)
    at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4961)
    at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5455)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
    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:634)
    at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1230)
    at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1876)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
    at java.util.concurrent.FutureTask.run(FutureTask.java:262)
    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:745)
Caused by: java.lang.AbstractMethodError: org.activiti.bpmn.converter.child.BaseChildElementParser.parseChildElement(Ljavax/xml/stream/XMLStreamReader;Lorg/activiti/bpmn/model/BaseElement;Lorg/activiti/bpmn/model/BpmnModel;)V
    at org.activiti.bpmn.converter.util.BpmnXMLUtil.parseChildElements(BpmnXMLUtil.java:126)
    at org.activiti.bpmn.converter.BaseBpmnXMLConverter.parseChildElements(BaseBpmnXMLConverter.java:253)
    at org.activiti.bpmn.converter.BaseBpmnXMLConverter.parseChildElements(BaseBpmnXMLConverter.java:243)
    at org.activiti.bpmn.converter.StartEventXMLConverter.convertXMLToElement(StartEventXMLConverter.java:55)
    at org.activiti.bpmn.converter.BaseBpmnXMLConverter.convertToBpmnModel(BaseBpmnXMLConverter.java:91)
    at org.activiti.bpmn.converter.BpmnXMLConverter.convertToBpmnModel(BpmnXMLConverter.java:426)
    at org.activiti.bpmn.converter.BpmnXMLConverter.convertToBpmnModel(BpmnXMLConverter.java:284)
    at org.activiti.engine.impl.bpmn.parser.BpmnParse.execute(BpmnParse.java:187)
    at org.activiti.engine.impl.bpmn.deployer.BpmnDeployer.deploy(BpmnDeployer.java:136)
    at org.activiti.engine.impl.persistence.deploy.DeploymentManager.deploy(DeploymentManager.java:58)
    at org.activiti.engine.impl.cmd.DeployCmd.execute(DeployCmd.java:106)

共有1个答案

崔绍辉
2023-03-14

您确定所有Activiti依赖项都使用相同的版本吗?从这个错误消息来看,我希望activiti-bpmn-model或activiti-bpmn-converter有不同的版本。

 类似资料:
  • 这段配置通过上下文进行扫描--我用调试器检查了它。问题可能出在哪里?

  • 问题内容: 我尝试执行此docker命令以使用Elasticsearch设置Jaeger Agent和Jaeger Collector。 但是此命令给出以下错误。如何用ElasticSearch配置Jaeger? 问题答案: 搜索解决方案一段时间后,我发现了一个docker-compose.yml文件,该文件具有Jaeger Query,Agent,collector和Elasticsearch配

  • 摘要/问题 我参与了一个使用的项目。该项目启用了maven,当我从cli运行时,一切都很顺利。 该项目也可以在NetBeans中打开,所有内容都可以正常显示,但是当我在eclipse中打开该项目时,我看到一些与相关的错误。在spring缓存中。xml位于“网页”文件夹下。这让我觉得eclipse项目可能不会被认为是一个动态web项目,但请遵循以下说明:https://www.mkyong.com/

  • 但是如果我让Spring Boot自动配置JOOQ,那么我应该把这个设置放在哪里呢? 基本的Spring Boot配置似乎只支持在中设置,如jooq-spring-boot-example所示。 我尝试将放入中,但这对SQL没有任何影响。 有没有办法自定义Spring boot JOOQ配置,而不必自己配置JOOQ? 我使用的是SpringBoot 2.1.7.Release和JOOQ 3.11.

  • 问题内容: 我将jaybird 2.2.3和hibernate 3.5一起使用,当我使用向导hibernate映射文件和pojos数据库时,出现以下错误“ java.lang.NullPointerException” 我在mysql上使用了相同的映射,并且可以正常工作,所以我相信这是jaybird中的问题 编辑: 有人能帮我吗? 问题答案: 在深入研究了Netbeans的代码并向Jaybird添

  • 如何使用Sonar 2.3和Maven 3.0配置JaCoCo。4. 我的项目是一个多模块Maven项目。我的顶级pom包括以下内容: 运行mvn声纳后:声纳我得到0%代码覆盖报告声纳。我应该看到至少50%。注意,我确实在每个子项目的目标文件夹中看到了jacoco.exec。