A simple reimbursement instance based on JBPM

Source: Internet
Author: User
Tags mysql database jbpm

Just beginning to learn jbpm simple entry examples:

Concept:

ProcessDefinition

Defines the business logic of the process, including business nodes and flows. It's a graph structure.

ProcessInstance

ProcessDefinition the embodiment of the implementation period. Contains information about the process definition after it is interpreted, such as start time, end time, and other associated information

Task

is part of the processdefinition that defines the specific content of the activity

Taskinstance

Task is interpreted as executing information, have start time, end time, participant, etc.

There are create start end three states

Actor

Participants in the event

JBPM currently only need actor ID, the specific explanation for actor is the business Application layer is responsible for

When a task is created, you can specify the participants for the task, or you can not specify

Token

is a pointer (the concept of the runtime) that represents an execution path that points to the node being executed in the current process

During the runtime of an instance, tokens may be a tree-shaped structure at the same time, there may be multiple token,

But there's only one root token.

I use the MySQL database, first modify the Hibernate.cfg.xml

Note that the Mysql-connector-java-3.2.0-alpha-bin version of the jar package when you introduce the database driver has a problem with the test, and I use the mysql-connector-java-5.1.5-bin version of the jar package

Java code

<!-- JDBC connection properties (begin) -->
   <property name="hibernate.dialect">org.hibernate.dialect.MySQLInnoDBDialect</property>
   <property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property>
   <property name="hibernate.connection.url">jdbc:mysql:///jbpm</property>
   <property name="hibernate.connection.username">root</property>
   <property name="hibernate.connection.password"></property>

   <!-- JDBC connection properties (end) -->

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.