【Introduction to JAVA Workflow】

Understand the basic concepts of JBPM (java Business Process Management):

 

JBPM, the full name of Java Business Process Management (Business Process Management), is an open-source, flexible and easily extensible executable process language framework covering business process management, workflow, service collaboration and other fields. jBPM is an open source project, and its use is subject to ASL (Apache License Version 2.0) and EULA (JBoss End User License Agreement) agreements.

 

jBPM is a flexible Business Process Management (BPM) Suite. It makes the bridge between business analysts and developers. Traditional BPM engines have a focus that is limited to non-technical people only. jBPM has a dual focus: it offers process management features in a way that both business users and developers like it.

 

Another feature of jBPM is that it uses Hibernate to manage its database. Hibernate is a very popular data storage layer solution in the Java field. As long as it is a database supported by Hibernate, jBPM also supports it. Through Hibernate, jBPM separates the data management functions and focuses on the processing of business logic.



 

 

jPDL - JBPM Process Definition Language

 

JBPM brief process:

1. Define the process (using JPDL)

2. Deployment process (deploy to database)

3. Create official documents and bind them to process instances

4. Through the interface of JBPM, the trigger process can flow downward

5. Through the interface of JBPM, the documents flowing to a certain user (that is, the list of pending tasks) can be obtained

6. You can end a user's task through the JBPM interface (this will trigger the process to continue to flow down)

7. So, until the end

 

 

Workflow is a technology that separates business operations and system processes. Workflow consists of four parts: Entity, Participant, Flow Definition, and Workflow Engine.

① The entity is the main body of the workflow, and it is an object that needs to flow with the workflow. For example, in a purchase requisition approval process, the entity is the purchase requisition; in an official document approval process, the entity is the official document.

② The participant is the responsible person in each processing step, it may be a person, a functional department, or an automated device;

③ Process definitions are predefined work steps that specify the flow of entities. It may be fully defined, that is, the next participant can be completely determined for each possible situation, or it may be incompletely defined, requiring the participant to decide the next participant according to the situation;

④ The workflow engine is a mechanism that drives entities to flow from one participant to the next according to the process definition

The first three elements are static, and the fourth element is dynamic, which combines the first three and is the core component of workflow.



 

 

work process

1) The operation of jBPM requires the support of the database, so the database to be used should be selected during system design. As long as it is a database supported by Hibernate, jBPM supports it. The initialization of the database can be done automatically by jBPM, or you can generate SQL statements through the ant generate.ddl task, and create the required tables by yourself outside jBPM.

2) Use jPdl to define the workflow and generate the processdinination.xml file. The GUI tool jPdl can be used, but only jBPM1.0 is currently supported, and there are many bugs. The XML DTD definition file is in the jBPM download package.

3) Ant create.pde generates the working directory of the pde package. Put the processdinination.xml file and other required files in the specified directory, and use ant build.precess.archives to generate the pde package. The format of the pde package is jar.

4) Change the relevant properties of the pde working directory /src/config/jbpm.properties, mainly to set the relevant database connection information. Note that the JDBC driver of the database should be placed in the lib directory of the pde working directory.

5) Ant deploy.process.archives deploys the pde just generated to the database. In fact, it is to insert some relevant data into the database.

6) Use the jBPM API function to develop the corresponding workflow.

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326991133&siteId=291194637