[midPoint] errorHandling controlFlow for tasks

Yakov Revyakin yrevyakin at gmail.com
Thu Jan 12 08:42:00 CET 2023


Thank you Paul,

Some more info.
UI highlights for "Retry later" in the "Error handling section" that
"Processing of the specified *account* should be retried later."
But my task is "Single bulk action task". There is no work with accounts.
So, the question - Is this option relevant to retry single bulk action
tasks or not?
If not how to reach reliable behavior of recurrent single bulk action tasks?

For example, a task has a groovy script making some Java rest calls.
Endpoint is not available and script raises an exception. The task gets
suspended status. What is the best practice to be sure that after some time
the task will continue its work?

Do I have to process exceptions with try/catch by myself or Midpoint is
able to retry after even RuntimeException?
How to get retries after exception managed - suspend after N retries?

Thanks,
J

On Wed, 11 Jan 2023 at 23:51, Paul Engle <pengle at rice.edu> wrote:

> I don't know if it's required or what happens by default if it's left out,
> but you might need a <situation> element in there:
> <entry>
>     <situation>
>         <status>fatal_error</status>
>     </situation>
> ...
> </entry>
>
> At least, that's what I have on one of my 4.4 server tasks, and it seems
> to perform as expected.
> Disclaimer: I just started playing with the new activity-based error
> handling yesterday, so I'm far from an expert.
>
> --
> Paul Engle
> IAM Architect
> Identity & Access Management
> pengle at rice.edu 713-348-4702
>
>
> On Wed, Jan 11, 2023 at 11:07 AM Yakov Revyakin via midPoint <
> midpoint at lists.evolveum.com> wrote:
>
>> Hi all,
>> It is not clear how to configure retry for a task.
>> I have a task which got fatal_error because of an incorrect accessKey for
>> an external resource. The task is suspended after the error.
>> I'd like to have another behavior - task must retry attempt to execute
>> after a minute.
>> I configured errorHandling in the activity section but still have the
>> same result - the task is suspended after an error and there is any retry.
>> What's wrong?
>>
>>     <activity>
>>     .......
>>         <controlFlow>
>>             <errorHandling>
>>                 <entry>
>>                     <reaction>
>>                         <retryLater>
>>                             <initialInterval>PT1M</initialInterval>
>>                             <nextInterval>PT3M</nextInterval>
>>                             <retryLimit>3</retryLimit>
>>                         </retryLater>
>>                     </reaction>
>>                 </entry>
>>            </errorHandling>
>>         </controlFlow>
>>     </activity>
>> _______________________________________________
>> midPoint mailing list
>> midPoint at lists.evolveum.com
>> https://lists.evolveum.com/mailman/listinfo/midpoint
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.evolveum.com/pipermail/midpoint/attachments/20230112/0f2f3418/attachment-0001.htm>


More information about the midPoint mailing list