`

[activiti.cfg.xml] cannot be opened because it does not exist

阅读更多

原文连接:http://www.hxstrive.com/article/120.htm

 

在搭建activiti环境时抛出的错误信息,从下面的信息中可以看出。抛出这个错误的原因是缺少activiti_cfg_xml文件。

 

问题信息:

2015-1-31 21:21:30 org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions

信息: Loading XML bean definitions from class path resource [activiti.cfg.xml]

Exception in thread "main" org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing XML document from class path resource [activiti.cfg.xml]; nested exception is java.io.FileNotFoundException: class path resource [activiti.cfg.xml] cannot be opened because it does not exist

at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:341)

at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:302)

at org.activiti.engine.impl.cfg.BeansConfigurationHelper.parseProcessEngineConfiguration(BeansConfigurationHelper.java:35)

at org.activiti.engine.impl.cfg.BeansConfigurationHelper.parseProcessEngineConfigurationFromResource(BeansConfigurationHelper.java:48)

at org.activiti.engine.ProcessEngineConfiguration.createProcessEngineConfigurationFromResource(ProcessEngineConfiguration.java:185)

at org.activiti.engine.ProcessEngineConfiguration.createProcessEngineConfigurationFromResourceDefault(ProcessEngineConfiguration.java:177)

at com.bug315.ActivitiTest01.main(ActivitiTest01.java:10)

Caused by: java.io.FileNotFoundException: class path resource [activiti.cfg.xml] cannot be opened because it does not exist

at org.springframework.core.io.ClassPathResource.getInputStream(ClassPathResource.java:141)

at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:328)

... 6 more

 

 

解决办法:

    在classpath目录下面缺少activiti.cfg.xml配置文件。创建activiti.cfg.xml配置文件。

<?xml version="1.0" encoding="UTF-8"?>

<beans xmlns="http://www.springframework.org/schema/beans"

    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

    xsi:schemaLocation="http://www.springframework.org/schema/beans

        http://www.springframework.org/schema/beans/spring-beans-3.1.xsd">

     

    <bean id="processEngineConfiguration"  

        class="org.activiti.engine.impl.cfg.StandaloneProcessEngineConfiguration">

        <property name="jdbcUrl" value="jdbc:mysql://localhost:3306/activiti" />

        <property name="jdbcDriver" value="com.mysql.jdbc.Driver" />

        <property name="jdbcUsername" value="root" />

        <property name="jdbcPassword" value="aaaaaa" />

        <property name="jobExecutorActivate" value="true" />

        <property name="databaseSchemaUpdate" value="true" />

    </bean> 

     

</beans>

 

原文连接:http://www.hxstrive.com/article/120.htm  

 

 

分享到:
评论

相关推荐

    整合activiti.cfg.xml文件到资源文件

    本文将深入探讨如何将`activiti.cfg.xml`文件整合到资源文件中,以便实现更灵活、高效的配置管理,同时兼顾应用的便捷性和适应性。 `activiti.cfg.xml`是Activiti引擎的主要配置文件,它定义了与数据库连接、事务...

    Activiti发布流程报错org.activiti.engine.ActivitiException: Error parsing XML

    郁闷啊,有时候不得不承认,无论是什么事,曾经是好的,到后边未必还是好的,不要拿曾经的种种来判断今天的结果, 前景:之前本地用jeecg(1.7版本)设计流程、发布流程、修改流程,所有的操作都是项目有汉字启动的,...

    eclipse安装activiti报错(requires 'org.eclipse.emf 2.6.0' but it could not be found)

    具体报错如下: Cannot complete the install because one or more required items could not be found. Software being installed: Activiti Eclipse BPMN 2.0 Designer 5.18.0.201508100929 (org.activiti....

    eclipse安装Activiti-designer 所需jar包

    Activiti Eclipse BPMN 2.0 Designer 5.18.0.201508100929 (org.activiti.designer.feature.feature.group 5.18.0.201508100929) requires 'org.eclipse.emf.transaction 1.4.0' but it could not be found

    activiti-cfg.jar.zip

    `activiti-cfg.jar`通常包含`activiti.cfg.xml`,这是Activiti引擎的核心配置文件,定义了数据库连接、事务管理、日志设置等一系列运行时参数。例如,你可以在这里配置数据库连接字符串、用户名和密码,以便Activiti...

    Activiti插件报错,需要的eclipse插件

    解决这个问题 Missing requirement: Activiti Eclipse BPMN 2.0 Designer 5.14.1 (org.activiti.designer.feature.feature.group 5.14.1) requires 'org.eclipse.emf.transaction 1.4.0' but it could not be found

    activiti5.x学习文档

    上述是 activiti5.x 学习文档的摘要信息,涵盖了 Activiti 的基本概念、工作流的概念、工作流的执行过程、Activiti 工作流引擎、BPMN、数据库、activiti.cfg.xml、logging.properties、准备环境、核心 API 等知识点...

    Eclipse离线集成activiti所需jar('org.eclipse.emf 2.6.0' but it could not be found解决方案)

    具体报错如下: Cannot complete the install because one or more required items could not be found. Software being installed: Activiti Eclipse BPMN 2.0 Designer 5.18.0.201508100929 (org.activiti....

    ActivitiDemo

    Activiti 是一个开源的工作流和业务自动化引擎,它支持业务流程建模、部署和执行。在"ActivitiDemo"这个项目中,我们看到的是一个基于Spring框架的简单Activiti实例,目的是为了展示如何将Activiti集成到Spring应用...

    eclipse Activiti 插件 jar包 出错

    org.activiti.designer.feature org.eclipse.graphiti.feature org.activiti.designer.eclipse org.activiti.designer.gui org.activiti.designer.help org.activiti.designer.integration org.activiti.designer....

    springboot+Activiti .zip

    1. 用户管理:用户是系统操作者,该功能主要完成系统用户配置。 2. 部门管理:配置系统组织机构(公司、部门、小组),树结构展现支持数据权限。 3. 岗位管理:配置系统用户所属担任职务。...集成activiti5.22

    Activiti.in.Action

    ### Activiti.in.Action:工作流必备文档与JBPM最佳替代品 #### 概述 《Activiti.in.Action》是一本详细介绍Activiti工作流引擎的书籍,由Tijs Rademakers编写,并得到了Tom Baeyens和Joram Barrez的推荐。本书...

    activiti.zip

    &lt;bean id="processEngineConfiguration" class="org.activiti.spring.SpringProcessEngineConfiguration"&gt; &lt;!-- 其他配置,如 jobExecutor、historyLevel 等 --&gt; &lt;bean id="processEngine" class="org...

    eclipse-emf for activity

    An error occurred while collecting items to be installed session context was:(profile=epp.package.jee, phase=org.eclipse.equinox.internal.p2.engine.phases.Collect, operand=, action=). Unable to read ...

    activiti-rest.zip

    2. **资源配置文件**:如 `activiti.cfg.xml`,这是 Activiti 引擎的主要配置文件,用来设置数据库连接、事务管理等参数。 3. **示例代码**:可能包含一些示例的 Java 类或 REST API 调用示例,展示如何启动流程...

    Kh-Activiti.zip

    - "Kh-Activiti"作为项目名,可能包含以下部分:源代码(src/main/java, src/main/resources),配置文件(如spring-context.xml, activiti.cfg.xml),Web资源(Web-INF目录下的web.xml,静态资源如CSS、JS),...

    MyEclipse配置Activiti插件所需补丁activiti.patch.rar

    【标题】"MyEclipse配置Activiti插件所需补丁activiti.patch.rar"涉及的关键知识点主要集中在MyEclipse集成开发环境以及Activiti工作流引擎的配置上。MyEclipse是基于Eclipse的一款强大的Java EE集成开发工具,它...

    activiti核心接口详解

    createStandaloneProcessEngineConfiguration 方法返回的是 StandaloneProcessEngineConfiguration 实例,该实例是标准的单例流程引擎配置对象,默认读取 activiti.cfg.xml 文件的配置。 1.1.2 ...

    org.activiti.designer.updatesite-5.18.1-SNAPSHOT.zip

    eclipse的activit插件org.activiti.designer.updatesite-5.18.1-SNAPSHOT,方便离线安装

    eclipse安装activiti报错

    Cannot complete the install because one or more required items could not be found. Software being installed: Activiti Eclipse BPMN 2.0 Designer 5.18.0.201508100929 (org.activiti.designer.feature....

Global site tag (gtag.js) - Google Analytics