jbpm使用配置(spring+hibernate+maven项目环境)


Maven 依赖名包

                <dependency>
			<groupId>org.jbpm.jbpm4</groupId>
			<artifactId>jbpm-api</artifactId>
			<version>4.4</version>
		</dependency>
		<dependency>
			<groupId>org.jbpm.jbpm4</groupId>
			<artifactId>jbpm-jpdl</artifactId>
			<version>4.4</version>
			<exclusions>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-engine</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-impl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.jbpm.jbpm4</groupId>
			<artifactId>jbpm-pvm</artifactId>
			<version>4.4</version>
			<exclusions>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-engine</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-impl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.jbpm.jbpm4</groupId>
			<artifactId>jbpm-bpmn</artifactId>
			<version>4.4</version>
			<exclusions>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-engine</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-impl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.jbpm.jbpm4</groupId>
			<artifactId>jbpm-log</artifactId>
			<version>4.4</version>
			<exclusions>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-engine</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-impl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.jbpm.jbpm4</groupId>
			<artifactId>jbpm-db</artifactId>
			<version>4.4</version>
			<exclusions>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-engine</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel-impl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>juel</groupId>
					<artifactId>juel</artifactId>
				</exclusion>
				<exclusion>
					<groupId>hsqldb</groupId>
					<artifactId>hsqldb</artifactId>
				</exclusion>
			</exclusions>
		</dependency>


spring 容器配置文件(applicationContext.xml)JBPM部分

        <!-- jbpm配置 -->
	<bean id="springHelper" class="org.jbpm.pvm.internal.processengine.SpringHelper"
		lazy-init="default" autowire="default">
		<property name="jbpmCfg">
			<value>jbpm.cfg.xml</value>
		</property>
	</bean>
	<bean id="processEngine" factory-method="createProcessEngine"
		factory-bean="springHelper" />
	<bean id="repositoryService" factory-bean="processEngine"
		factory-method="getRepositoryService" />
	<bean id="executionService" factory-bean="processEngine"
		factory-method="getExecutionService" />
	<bean id="historyService" factory-bean="processEngine"
		factory-method="getHistoryService" />
	<bean id="managementService" factory-bean="processEngine"
		factory-method="getManagementService" />
	<bean id="taskService" factory-bean="processEngine"
		factory-method="getTaskService" />
	<bean id="identityService" factory-bean="processEngine"
		factory-method="getIdentityService" />


jbpm 配置 (jbpm.cfg.xml)

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

<jbpm-configuration>
   <import resource="jbpm.default.cfg.xml" />
  <import resource="jbpm.businesscalendar.cfg.xml" />
  <import resource="jbpm.tx.hibernate.cfg.xml" />
  <import resource="jbpm.jpdl.cfg.xml" />
  <import resource="jbpm.bpmn.cfg.xml" />
  <import resource="jbpm.identity.cfg.xml" />
  <import resource="jbpmpackage/leave.jpdl.xml"></import>

  <!-- Job executor is excluded for running the example test cases. -->
  <!-- To enable timers and messages in production use, this should be included. -->
  <!--
  <import resource="jbpm.jobexecutor.cfg.xml" />
  -->
</jbpm-configuration>


郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。