metabase / metabase

The simplest, fastest way to get business intelligence and analytics to everyone in your company :yum:
https://metabase.com
Other
38.3k stars 5.08k forks source link

Log events when Alerts Fail or are successful #34519

Open Tony-metabase opened 11 months ago

Tony-metabase commented 11 months ago

Is your feature request related to a problem? Please describe. Currently if an Alert Fails it fails in the background. You can find an error in the Admin -> Troubleshooting -> Logs but for non technical people it's hard to troubleshoot and it would be good that you get notified of these issues

Describe the solution you'd like Add an event that would show if an alert/subscription was successful/failed ... This can be then added to the Audit v2 as part of the offering or be used somewhere else in the frontend but at least it should be tracked

Describe alternatives you've considered None apart from parsing the logs

How important is this feature to you? Can impact users that forgot they setup an Alert and something happens. This will cause the alert to fail in the background and the user having the false illusion that everything is fine. For example someone deleting the slack channel by mistake and thins

qnkhuat commented 4 months ago

We've added a status column to task_history with 3 possible values: started, success, failed in https://github.com/metabase/metabase/pull/42372

You can inspect this from the Admin/Task tab, does this solve your need?

Tony-metabase commented 4 months ago

@qnkhuat This is good! but i had a look at

image

Just curious but what kind of details are we expecting when a send-pulse is triggered? My assumption is that send-pulse is the one that triggers the subscription but if this fails what kind of information am i expecting? when such a task fails or just that status is failed?

ixipixi commented 2 months ago

@qnkhuat I have the same question Tony has. Would we expect to see a "Fail" status? Does this provide admins with any clue as to why the failure occurred?

qnkhuat commented 2 months ago

you should have an exception/failure info in the task_details of the failed tasks.

qnkhuat commented 2 months ago

I'm open to ideas for how to improve the debugging experience here, let me know if you have ideas or want to chat.

Tony-metabase commented 2 months ago

If we get the failure detail that would be great! And this is on release 50? Since we do get a number of these issues and we can experiment with this on real scenarios. It might be enough for now but we need to test it in a real setting

qnkhuat commented 2 months ago

yes it's on 50

Tony-metabase commented 2 months ago

Awesome! once cloud is on 50 we will have a lot of testing examples :)

ixipixi commented 3 weeks ago

If we send a pulse to a Slack channel and it fails because the channel doesn't exist - this is visible in the troubleshooting logs but the task page still displays as a "Success". Is that expected behavior?

ixipixi commented 3 weeks ago

I have a customer that's trying to iron out why a specific subscription from August was not delivered. Maybe this would be a good time to look at their use case, identify what steps must be taken in order to answer that question and see if we're able to make it simpler to do?

qnkhuat commented 3 weeks ago

not expected, please create a bug for that.

ixipixi commented 1 day ago

https://github.com/metabase/metabase/issues/48209