camunda/camunda-bpm-platform

In Cockpit, UserOperationLog is missing for increment retries on ExternalTask

Closed this issue · 2 comments

Environment (Required on creation)

  • Any Camunda version
  • Any DB
  • BPMN diagram with External Task
  • External Task Client that fails the External Task

Description (Required on creation; please attach any relevant screenshots, stacktraces, log files, etc. to the ticket)

When incrementing the retries on an External Task in Cockpit (e.g. when it has no retries left, the number of retries can be incremented from the incident view), no user operation log is shown on the history view under the User Operations tab.

Steps to reproduce (Required on creation)

  • Deploy a process definition with a single External Task.
  • Start an instance of that definition and make the External Task fail through an External Task Client.
  • In Cockpit, navigate to the Runtime view of the process instance. An incident should be displayed (since the External Task failed).
  • From the Incidents tab, increment the number of retries for the External Task.
  • Navigate to the History view of the process instance.
  • On the User Operations tab, there is no entry for the increment retry user operation.

Observed Behavior (Required on creation)

No user operation is displayed on the User Operations tab in the history view of an External Task that had its retries incremented.

Expected behavior (Required on creation)

The user operation that is produced when incrementing the retries of a failed External Task is displayed in the User Operation tab in the history view of an External Task in Cockpit.

Root Cause (Required on prioritization)

Cockpit filters the user operation log entries by entityType. only operation log entries with entityTypes ProcessInstance, Job%, and Variable are displayed.

The query that Cockpit sends is: http://localhost:8080/camunda/api/engine/engine/default/history/user-operation?sortBy=timestamp&sortOrder=desc&firstResult=0&maxResults=50&processInstanceId=fab250f3-174f-11ef-8704-84a9385a812f&entityTypeIn=ProcessInstance%2CJob%2CVariable.
The query that would include entityType ExternalTask is: http://localhost:8080/camunda/api/engine/engine/default/history/user-operation?sortBy=timestamp&sortOrder=desc&firstResult=0&maxResults=50&processInstanceId=fab250f3-174f-11ef-8704-84a9385a812f&entityTypeIn=ProcessInstance%2CJob%2CVariable%2CExternalTask

Solution Ideas

Add entityType ExternalTask to the query parameters.

Hints

Links

https://jira.camunda.com/browse/SUPPORT-21989

Breakdown

Pull Requests

Dev2QA handover

  • Does this ticket need a QA test and the testing goals are not clear from the description? Add a Dev2QA handover comment

Will backport it after review.

Verified on 7.22.0-SNAPSHOT

Image