整合步骤: * 导入jbpm的jar包 * 删除db和hibernate的jar包 * 在config下创建一个配置文件 config/jbpm jbpm.cfg.xml jbpm.hibernate.cfg.xml * jbpm.cfg.xml文件中 <import resource=”jbpm.tx.hibernate.cfg.xml” />改为 <import resource=”jbpm.tx.spring.cfg.xml” /> 统一由spring处理事务,,由右边的配置可以看出是通过创建新的session从而开启事务的 * jbpm.hibernate.cfg.xml文件中 * 数据库的连接配置 <property>thread</property> 这行配置不能写,不能从当前线程中获取session * 项目本身的表的映射文件 * jbpm的表的映射文件 * spring的配置文件 * hibernate配置文件的路径修改 <bean> <property> <value>classpath:jbpm/jbpm.hibernate.cfg.xml</value> </property> </bean> * 让spring产生processEngine <bean> <property value=”jbpm/jbpm.cfg.xml”></property> </bean>
<bean factory-bean=”springHelper” factory-method=”createProcessEngine” /> 注意jbpm.cfg.xml配置文件的路径
接受失败等于打破完美的面具,接受失败等于放松自己高压的心理,