getsentry / sentry

Developer-first error tracking and performance monitoring
https://sentry.io
Other
37.54k stars 4.04k forks source link

Default notifications to team slack channels #66756

Open florentsarat opened 3 months ago

florentsarat commented 3 months ago

Problem Statement

When a new issue is assigned to a team, we need to send a slack notification to their feed.

The feed channel is a slack channel dedicated to a given team that is monitored by the team's duty. The team's duty is never the same user. The goal of the team's duty is manage the RUN. Therefore seing new Sentries is key for them.

As today with the Slack integration, individual user receive Slack alerts (with the general alert notifications settings).

Another possibility is to use alerts, however they need to be defined team by team and project by project. This can lead to a lot of configuration (50 teams, with 3 projects each thats 150 alerts to setup...)

Solution Brainstorm

The Slack integration already allows connecting a team to a given Slack channel (not that it could also be applied other tools such as Teams)

Ideally we would need a way to setup notifications for a team (similar ui as in "Settings" > "Account" > "Notifications" but for a team).

Product Area

Settings - Integrations

getsantry[bot] commented 3 months ago

Assigning to @getsentry/support for routing ⏲️

getsantry[bot] commented 3 months ago

Routing to @getsentry/product-owners-alerts for triage ⏲️

schew2381 commented 3 months ago

Hi thanks for the feedback around notifications and alert rules! Just wanted to update that I'm waiting to hear back from someone who works in that area and will know more

rachrwang commented 3 months ago

@florentsarat, thank you for filing this issue. Making alerts easier to configure is a priority for us.

I'd like to learn more about your use case to make sure we understand your needs:

  1. Can you share more about how you've configured/ use alerts today within Sentry?
  2. You mentioned team assignment as a main trigger for the alert - are there other cases that you'd want a alert to fire (for example, when a certain number of events or users are impacted?)
  3. Based on your example - it sounds like you'd want alerts from all 3 projects to funnel into one team channel. Can you share more about how you've configured projects? We have some upcoming projects related to project setup, which in turn will impact alerts, so it'd be helpful for us to better understand how you're approaching project setup

If it's easier to chat live or over email, you can reach me at rachel.wang@sentry.io. thanks!

florentsarat commented 3 months ago

@rachrwang Thank you for the reply.

  1. We have little to no alerts in Sentry today. We would like to increase their usage.
  2. Inform teams that a new Sentry was assigned to them is the main use case. I don't mind letting them configure on their own more detailed alerting.
  3. We have a monolithic architecture with 50 teams working on it. There are three projects per environment (two for front-end and one for back-end), resulting in a total of six projects for staging and production environments.

Let's use the back-end project as an example. When a new issue occurs in this project, it will be assigned to a specific team based on code ownership (e.g., Team A). We want to notify that team. Similarly, if another issue occurs in a different file within the same project, we need to inform Team B.

Now we don't want to warn individuals. Ours teams have both build and run activities. To manage both activities, we have the concept of dev duty. Every day a different dev is the duty and will do so run which include Sentry issues.

This dev will look into the "feed" channel of his team to monitor alerts from Sentry and other systems while others ignore it.

Another great perk of feed channels is that it allows devs to also collaborate on the resolution together (by replying to the tread).

I'll sent you an email to discuss this further.

rachrwang commented 3 months ago

Thank you for sharing that example - I look forward to talking soon!

raulparada commented 2 months ago

Hi, this is our exact use case as well (great description @florentsarat) and really all what I expected from doing /sentry link team on Slack. Spent two hours figuring out that this does not work, and after this I still don't get what /sentry link team does? i.e. once the team is linked to a Slack channel, what will that channel receive and when?

To summarise my feedback, the flow would be:

Thanks!

ceorourke commented 2 months ago

@raulparada /sentry link team sets the channel the command was typed in as the destination for issue alerts when the action is "Send a notification to Team abc"

An alert like this will notify the team in the Slack channel that was set up:

Screenshot 2024-04-12 at 2 33 30 PM

I hope that helps, I agree this isn't super clear to users.