Configuration and use of listeners in Activiti

Source: Internet
Author: User

In the Activiti process engine, the listener is very important.

There are two types of activiti monitoring, one is the task listener and the other is the execution listener.

Task listener: Automatically gets the manager of the department where the "leave" is located when the manager takes a leave task.

Execute listener: Automatically modifies the status of leave slip as approved after the task finishes.

Let me implement the listener specifically.

The first is the task listener.

1. Creating a class to act as a listener requires implementing the Tasklintener interface.

2. In the implemented interface method, complete the logic.

3. Configure the listener in the process.


The following is the configuration




Here's another listener:

Execute listener

The steps to implement the listener are similar to the task listener, but the interface that the execution listener implements is Executionlintener

Then in the configuration.


And then it's configured



This is the use of listeners in the process engine. Hope to learn Activiti friends have help ...



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.