Task Notifications

Last modified 30 Mar 2022 13:35 +02:00

Task manager provides the following notifications:

Event Recipient(s) Comment

Task handler execution start

task owner

Emitted when a task handler execution is started.

Task handler execution finish

task owner

Emitted when a task handler execution finishes.

Some examples

The following snippet of the system configuration object can be used to configure task notifications:

            <transport>mail</transport>      <!-- all starts and finishes are reported by mail (can generate a lot of messages, e.g. when live sync is used -->
            <operation>delete</operation>    <!-- DELETE means finishing task handler execution -->
            <status>onlyFailure</status>     <!-- this corresponds to the FATAL_ERROR result -->
            <operation>delete</operation>    <!-- DELETE means finishing task handler execution -->
                <script>                     <!-- any situation that results in the task being suspended -->
         <redirectToFile>d:\midpoint\home\mail-notifications.txt</redirectToFile>		<!-- just for debugging -->
     <sms> ... </sms>

A notification looks like this:

============================================ Tue Jun 21 18:07:42 CEST 2016
To: admin@evolveum.com
Subject: Task 'Reconcile CSV1' finish notification: FATAL_ERROR

Notification about task-related operation.

Task: Reconcile CSV1
Handler: http://midpoint.evolveum.com/xml/ns/public/model/synchronization/task/reconciliation/handler-3

Run result status: PERMANENT_ERROR
Message: Reconciliation without an object class specification is not supported
Progress: 0

Notification created on: Tue Jun 21 18:07:42 CEST 2016

Task owner: midPoint Administrator (administrator)
Channel: http://midpoint.evolveum.com/xml/ns/public/provisioning/channels-3#reconciliation

The following information is available:

Field Meaning Comment


The name of the task. Usually it is self-explaining.


Handler that starts or finishes its execution. Most tasks have exactly one handler. However, some workflow-related tasks can have more (sometimes up to 4) handlers. Each handler start/stop is sent as a standalone event.

Run result status

Result of the handler execution, driving what will be done with the task. Can have values of PERMANENT_ERROR, TEMPORARY_ERROR, FINISHED, FINISHED_HANDLER, INTERRUPTED, RESTART_REQUESTED. (TODO - more information)

Can be tested with isPermanentError(), isTemporaryError(), isFinished(), isInterrupted(), isRestartRequested() event methods.


Status as stored in the task’s operation result. Can have values of SUCCESS, HANDLED_ERROR, WARNING, PARTIAL_ERROR, FATAL_ERROR, IN_PROGRESS, NOT_APPLICABLE.

Can be tested with <status> filter, or with isSuccess() - corresponds to SUCESS, HANDLED_ERROR, WARNING, isOnlyFailure() - corresponds to FATAL_ERROR, isFailure() - corresponds to PARTIAL_ERROR or FATAL_ERROR.


Message that is part of the operation result, if present.

Retrieved via event.getMessage().


Progress reported by the task.

Retrieved via event.getProgress().

So, if you want to send notifications when a problem occurs, it is most advisable to use expressionFilter of event.isPermanentError(), as in the third example.

Was this page helpful?
Thanks for your feedback