elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
19.8k stars 8.19k forks source link

[Reporting] Classify user errors correctly #196620

Open tsullivan opened 1 day ago

tsullivan commented 1 day ago

If a report job fails, the failure is marked as an "unsuccessful" task outcome by Task Manager metrics. However, there are certain cases where a failure can be due to user configuration and would be expected:

  1. If the report job depends on a saved object, and that saved object is deleted before the report task runs
  2. If the authentication that is cached in the report job document becomes invalid before the report task runs.

This issue is to update Reporting code to account for these kinds of cases when handling errors, so that task outcomes metrics aren't affected.

An example of how this is done elsewhere is here (note throw createTaskRunError(err, TaskErrorSource.USER);).

elasticmachine commented 1 day ago

Pinging @elastic/appex-sharedux (Team:SharedUX)