1、安装jpdl插件到myeclipse。http://www.cnblogs.com/chuyuhuashi/archive/2012/03/27/2418841.html
2.下载jbpm4.4.把
J:\jbpm\jbpm-4.4\install\src\cfg\jbpm下的spring.jbpm.cfg复制到新项目中,改为jbpm.cfg.xml
新建hibernate.properties文件:
dataSource.password=root
dataSource.username=root
dataSource.databaseName=jbpmdb
dataSource.driverClassName=com.mysql.jdbc.Driver
dataSource.dialect=org.hibernate.dialect.MySQLInnoDBDialect
dataSource.serverName=localhost:3306
dataSource.url=jdbc:mysql://${dataSource.serverName}/${dataSource.databaseName}
dataSource.properties=user=${dataSource.username};databaseName=${dataSource.databaseName};serverName=${dataSource.serverName};password=${dataSource.password}
dataSource.hbm2ddl.auto=update
applicationContext.xml文件:
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:tx="http://www.springframework.org/schema/tx"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.5.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd">
<context:annotation-config />
<bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer" p:location="hibernate.properties" p:ignoreUnresolvablePlaceholders="true"/>
<bean id="springHelper" class="org.jbpm.pvm.internal.processengine.SpringHelper" />
<bean id="processEngine" factory-bean="springHelper" factory-method="createProcessEngine" />
<bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
<property name="dataSource" ref="dataSource" />
<property name="mappingResources">
<list>
<value>jbpm.repository.hbm.xml</value>
<value>jbpm.execution.hbm.xml</value>
<value>jbpm.history.hbm.xml</value>
<value>jbpm.task.hbm.xml</value>
<value>jbpm.identity.hbm.xml</value>
</list>
</property>
<property name="hibernateProperties">
<props>
<prop key="hibernate.dialect">${dataSource.dialect}</prop>
<prop key="hibernate.hbm2ddl.auto">${dataSource.hbm2ddl.auto}</prop>
</props>
</property>
</bean>
<bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
<property name="sessionFactory" ref="sessionFactory" />
<property name="dataSource" ref="dataSource" />
</bean>
<bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource">
<property name="driverClassName" value="${dataSource.driverClassName}" />
<property name="url" value="${dataSource.url}" />
<property name="username" value="${dataSource.username}" />
<property name="password" value="${dataSource.password}" />
</bean>
</beans>
3.测试用的流程test.jpdl.xml,test将作为jpdl的process的name
<?xml version="1.0" encoding="UTF-8"?>
<process xmlns="http://jbpm.org/4.4/jpdl" name="test">
<start g="94,64,48,48" name="start1">
<transition g="-52,-22" name="A" to="A"/>
</start>
<task assignee="A" g="73,195,92,52" name="A">
<transition g="-52,-22" name="B" to="B"/>
</task>
<task assignee="B" g="266,192,92,52" name="B">
<transition g="-40,-21" name="end" to="end1"/>
</task>
<end g="290,327,48,48" name="end1"/>
</process>
http://www.blogjava.net/pengo/archive/2010/01/04/308219.html
http://www.blogjava.net/wangxinsh55/archive/2011/07/24/354925.html
分享到:
相关推荐
spring与jbpm的集成包(符集成方法)
jbpm4 集成 spring 的试用代码 spring2.5 hibernate3.3 jbpm4 beta1 后的svn版本
jbpm与spring集成开发指南,描述了jbpm与spring开发过程。
jbpm5.4 spring mvc 集成开发 Jetty maven JTA 事务等配置!
jbpm spring驱动,这个驱动用于jbpm集成spring情况。
JBPM与Spring集成开发指南.docx
JBPM4.3与Spring会签 实例,欢迎交流ningjinlin@gmail.com
JBPM与Spring集成开发指导书.docx
JBPM与Spring集成开发指导书.doc
jbpm 4.3 与 spring 集成
jbpm4.3与spring整合的一个小文档
介绍JBPM基本内容和与Spring集成关键点。文章没有排版,但内容很有价值。
spring+jbpm的配置示例,jbpm配置,希望大家一起进行学习,共同提高
Spring与JBoss JBPM工作流集成开发指南.pdf
近期网上有人介绍jBPM4与Spring整合的2种方式,但没有人贴出代码,闲着无聊写了个例子,源码见附件,在WEBLOGIC下运行正常,事务由spring控制http://ip:7001/Spring/helloWorld.do
风中叶老师讲的JBPM4与Spring整合例子代码 JBPM4 Spring OA工作流系统
如何将Spring与JBPM集成,需要的包
因为有点大所以分了8份 一个自己学习到现在的结果吧,自己做的一个完整的借款流程应用,主要是用到了SPRING,在整合的过程中遇到过不少问题。我的博客有一些说明http://yuyanshan.javaeye.com/<br>
因为有点大所以分了8份 一个自己学习到现在的结果吧,自己做的一个完整的借款流程应用,主要是用到了SPRING,在整合的过程中遇到过不少问题。我的博客有一些说明http://yuyanshan.javaeye.com/<br>