Page MenuHomePhabricator

ST5.4.2 Toolforge Alerting System
Closed, ResolvedPublic

Description

Hypothesis text

If we provide an opt-in email alerting service to notify webservice maintainers by email when their webservices are down*, then maintainers sign up to receive alerts for their most critical tools.

*Down definition for this KR:
- Rise in 500 errors
- Webservice not responding
- Webservice restarting often

Related Objects

Event Timeline

fnegri changed the task status from Open to In Progress.Jul 24 2026, 2:47 PM
fnegri claimed this task.
fnegri moved this task from Backlog to In progress on the tools-platform-team board.
fnegri changed the status of subtask T432863: Define alert conditions in Prometheus (if possible) from Open to In Progress.
aputhin triaged this task as High priority.Jul 28 2026, 4:07 PM

Noting some additional things that came out of a discussion with @dcaro that we still need to think through / answer:

  1. We still need to clarify what it means for a user to 'action' on an alert. We discussed just looking at the alerting condition being resolved, or someone logging into the bastion, but not sure we settled on something final. Anything that relies on implicit proxies for action come with their own set of drawbacks and don't account for users intentionally ignoring alerts because they either resolve themselves or aren't really an issue, but adding a full alerting acknowledgement system increases the scope and feels like overkill.
  2. Do we want to send an email when an alert is clear? This seems useful to avoid having someone receive an alert, not see it / be able to respond until later, only to realize that there is no longer anything to worry about.
  3. Do we need to think about silence periods for alerts (weekends, nights)? I'm thinking not for the MVP (and maybe not ever, unless it's configurable) because we really have no insight into users' schedules or preferences. Plus, the idea is just to inform them, not to turn this into full blown incident response.
  4. Do we want users to be able to look at a list of alerts somewhere other than their email inbox, like through the CLI? This probably would require adding an API that can fetch the alerts per tool. That's added scope, but could be reused for eventual use in a Toolforge UI dashboard. IMO this feels borderline important for the MVP, so I wouldn't consider it high priority, but it would be nice to have.

Do we want users to be able to look at a list of alerts somewhere other than their email inbox, like through the CLI?

I think we'll get this for free as the alerts will appear on https://alerts.wikimedia.org/ and we should be able to filter them by tool name. I don't remember if you need special permissions to access that page or if a Toolforge account is enough. I expect the same alerts to be visible also in https://grafana.wmcloud.org/alerting/list (which does not require login) and https://prometheus-alerts.wmcloud.org/ (which does require login).

We can test this after we add the alerts to prometheus in T432863: Define alert conditions in Prometheus (if possible).

Do we want users to be able to look at a list of alerts somewhere other than their email inbox, like through the CLI?

I think we'll get this for free as the alerts will appear on https://alerts.wikimedia.org/ and we should be able to filter them by tool name.

It's not public, and I'd strongly recommend not to direct users to karma/prometheus if we can avoid it (ex. put the cli in front just doing an api call for them to list the alerts).

I'd strongly recommend not to direct users to karma/prometheus

Fair enough, tooling might change and we don't want Toolforge users to rely on it. Toolforge UI will be the natural place for this.

As part of this hypothesis, I don't think we have enough time to implement a CLI or API access to list the active alerts, but it can be definitely added in the future.

I'd strongly recommend not to direct users to karma/prometheus

Fair enough, tooling might change and we don't want Toolforge users to rely on it. Toolforge UI will be the natural place for this.

As part of this hypothesis, I don't think we have enough time to implement a CLI or API access to list the active alerts, but it can be definitely added in the future.

Agree that Toolforge UI will be the go-to place for checking alert history. The most important part of the hypothesis is that users can start receiving the alerts, but we should at least be storing them so past alerts can be eventually retrieved. a.k.a. let's not lose data from this period pre-API.

Agree that Toolforge UI will be the go-to place for checking alert history. The most important part of the hypothesis is that users can start receiving the alerts, but we should at least be storing them so past alerts can be eventually retrieved. a.k.a. let's not lose data from this period pre-API.

Sounds reasonable to me, we can come back to this after the MVP release.

we should at least be storing them so past alerts can be eventually retrieved. a.k.a. let's not lose data from this period pre-API.

I discussed this with @aputhin and @CCiufo-WMF, while I agree that storing the past alerts would be a nice feature, I suggested treating it as a "nice to have" in the context of the current hypothesis.

We don't need to implement the storage right away: when we implement the feature to "list the past alerts", we can add a note to the output specifying "Listing all alerts starting from YY-MM-DD", where the date is max(storage_start, now - retention_window). Initially we will only show a few days of alerts, but over time this will grow up to a desired retention window (we probably don't want to show alerts older than X months anyway).

Note: we are experimenting with cross-posting to Phabricator the weekly report that previously was only posted to Asana, where only few people have access.

Summary

  • Hypothesis text
    • If we provide an opt-in email alerting service to notify webservice maintainers by email when their webservices are down, then maintainers sign up to receive alerts for their most critical tools.
  • Progress update on the hypothesis for the week, including if something has shipped
    • Hypothesis lifecycle stage: Build phase (list of phases)
    • We completed the scaffolding for the new service, including a stub poller that just logs "not implemented yet" every minute, and deployed it to production (T435971)
  • Any updates on metrics related to this hypothesis (including baseline, target, or actuals, if applicable)
    • No
  • Any emerging blockers or risks
    • No
  • Any unresolved dependencies - do you depend on another team that hasn’t already given you what you need? Are you on the hook to give another team something you aren’t able to give right now?
    • No
  • Have there been any new lessons from the hypothesis?
    • No
  • Have there been any changes to the hypothesis scope or timeline?
    • We didn't touch the Sep, 30th timeline for the hypothesis, but we decided to adjust the intermediate phases to give more time for development. Completion of the "Build phase" is now expected by Sep, 16th. The following phases shifted accordingly, filling the 5-day unallocated time in the previous timeline.

Next steps

  • Implement the alert polling code, following the PoC that we created last week (T432865)
  • Deploy the new endpoint to list opted-in tools (T433690)
  • Define the template for the emails that will be sent to tool maintainers (T437081)

Note: we are experimenting with cross-posting to Phabricator the weekly report that previously was only posted to Asana, where only few people have access.

(update from Sep, 11th that I forgot to post here last week)

Summary

  • Hypothesis text
    • If we provide an opt-in email alerting service to notify webservice maintainers by email when their webservices are down, then maintainers sign up to receive alerts for their most critical tools.
  • Progress update on the hypothesis for the week, including if something has shipped
    • Hypothesis lifecycle stage: Build phase (list of phases)
    • We deployed the new endpoint to list opted-in tools (T433690)
    • Progress was made on writing the code to poll prometheus and send emails, but the code is not ready for review yet (T432865)
    • Progress was slower this week because Francesco was attending a conference
  • Any updates on metrics related to this hypothesis (including baseline, target, or actuals, if applicable)
    • No
  • Any emerging blockers or risks
    • No
  • Any unresolved dependencies - do you depend on another team that hasn’t already given you what you need? Are you on the hook to give another team something you aren’t able to give right now?
    • No
  • Have there been any new lessons from the hypothesis?
    • No
  • Have there been any changes to the hypothesis scope or timeline?
    • We didn't touch the Sep, 30th timeline for the hypothesis, but we added another 2 days for the "Build phase", which is now targeting Sep, 18th.

Next steps

  • Complete, review and deploy the code for polling prometheus and sending emails to opted-in tools (T432865)
  • Implement the opt-in/opt-out mechanism for users (T432864)
  • Finalize the email template (T437081)

Note: we are experimenting with cross-posting to Phabricator the weekly report that previously was only posted to Asana, where only few people have access.

Summary

  • Hypothesis text
    • If we provide an opt-in email alerting service to notify webservice maintainers by email when their webservices are down, then maintainers sign up to receive alerts for their most critical tools.
  • Progress update on the hypothesis for the week, including if something has shipped
    • Hypothesis lifecycle stage: Build phase (list of phases)
    • The poller service is now polling the production Prometheus servers and filtering alerts, but alerting emails are not being sent yet (T432865)
    • We discussed what the alerting emails should include, and created a draft of how they will look like (T437081)
    • We discussed and implemented the mechanism for users to opt in to receiving alerts, and the code is currently in review (T432864)
    • We prepared a communication plan and a draft page on wikitech describing the new feature
  • Any updates on metrics related to this hypothesis (including baseline, target, or actuals, if applicable)
    • No
  • Any emerging blockers or risks
    • No
  • Any unresolved dependencies - do you depend on another team that hasn’t already given you what you need? Are you on the hook to give another team something you aren’t able to give right now?
    • No
  • Have there been any new lessons from the hypothesis?
    • No
  • Have there been any changes to the hypothesis scope or timeline?
    • We decided to postpone the target date for the hypothesis by two weeks, in order to prepare for the Discord call scheduled for next week and still have enough time for testing the new features before releasing them to users

Next steps

  • Complete the implementation for sending notification emails (T432865)
  • Finalize the email template (T437081)
  • Deploy the opt-in/opt-out mechanism for users (T432864)

Note: we are experimenting with cross-posting to Phabricator the weekly report that previously was only posted to Asana, where only few people have access.

Summary

  • Hypothesis text
    • If we provide an opt-in email alerting service to notify webservice maintainers by email when their webservices are down, then maintainers sign up to receive alerts for their most critical tools.
  • Progress update on the hypothesis for the week, including if something has shipped
    • Hypothesis lifecycle stage: Build phase
    • We completed the implementation of the notification logic (when notifications should be sent), the code was reviewed and the review comments were addressed (T432865)
    • We iterated on the notification email template, which is close to its final version (T437081)
    • The mechanism for users to opt in to receiving alert notifications was deployed and is live in production (but has no effect yet) (T432864)
    • We held a Discord call with the technical community (slides) where we presented this and other upcoming features and received some valuable feedback
  • Any updates on metrics related to this hypothesis (including baseline, target, or actuals, if applicable)
    • No
  • Any emerging blockers or risks
    • Parts of the code are still in development and will require code reviews and testing. The target date of October 2 for completing the Build phase is tight and could be at risk if there's any unexpected issue next week.
  • Any unresolved dependencies - do you depend on another team that hasn’t already given you what you need? Are you on the hook to give another team something you aren’t able to give right now?
    • No
  • Have there been any new lessons from the hypothesis?
    • No
  • Have there been any changes to the hypothesis scope or timeline?
    • No

Next steps

  • Finalize the email template (T437081)
  • Push the missing parts of the code (sending the notification emails, reading the opt-in value from components-api), get them reviewed and deployed (T432865)
  • Test the end-to-end flow with a test tool, then start sending email notifications to all users who opted in (T432865)
  • Write documentation pages in Wikitech

Note: we are experimenting with cross-posting to Phabricator the weekly report that previously was only posted to Asana, where only few people have access.

Summary

  • Hypothesis text
    • If we provide an opt-in email alerting service to notify webservice maintainers by email when their webservices are down, then maintainers sign up to receive alerts for their most critical tools.
  • Progress update on the hypothesis for the week, including if something has shipped
    • Hypothesis lifecycle stage: Build phase
    • Finalized the email template for all types of alerts (T437081)
    • Email notifications are live and working in production, enabled only for a single test tool (T432865)
    • A user documentation page was added to Wikitech
  • Any updates on metrics related to this hypothesis (including baseline, target, or actuals, if applicable)
    • No
  • Any emerging blockers or risks
    • No
  • Any unresolved dependencies - do you depend on another team that hasn’t already given you what you need? Are you on the hook to give another team something you aren’t able to give right now?
    • No
  • Have there been any new lessons from the hypothesis?
    • No
  • Have there been any changes to the hypothesis scope or timeline?
    • No

Next steps

  • Turn on the alerting emails for all Toolforge tools that enable the notifications in their tool config (T439554)

Note: we are experimenting with cross-posting to Phabricator the weekly report that previously was only posted to Asana, where only few people have access.

Summary

  • Hypothesis text
    • If we provide an opt-in email alerting service to notify webservice maintainers by email when their webservices are down, then maintainers sign up to receive alerts for their most critical tools.
  • Progress update on the hypothesis for the week, including if something has shipped
    • Hypothesis lifecycle stage: Build phase
    • Continued testing the new feature with a test tool (test-maintainer-alerts) and created several follow-up tasks for small issues that were identified. None of these issues are blocking the beta release.
    • Implemented and reviewed the code that checks the list of opted-in tools (T439554). This is ready to be deployed.
    • Prepared a draft email to announce the feature to Toolforge users.
  • Any updates on metrics related to this hypothesis (including baseline, target, or actuals, if applicable)
    • No
  • Any emerging blockers or risks
    • If we stick to the current timeline, we only have 1 week to complete both the pilot phase and the stabilization phase (original plan was 1 week for each, so 2 weeks total)
  • Any unresolved dependencies - do you depend on another team that hasn’t already given you what you need? Are you on the hook to give another team something you aren’t able to give right now?
    • No
  • Have there been any new lessons from the hypothesis?
    • No
  • Have there been any changes to the hypothesis scope or timeline?
    • No

Next steps

Note: we are experimenting with cross-posting to Phabricator the weekly report that previously was only posted to Asana, where only few people have access.

Summary

  • Hypothesis text
    • If we provide an opt-in email alerting service to notify webservice maintainers by email when their webservices are down, then maintainers sign up to receive alerts for their most critical tools.
  • Progress update on the hypothesis for the week, including if something has shipped
    • Hypothesis lifecycle stage: Pilot/Release phase
    • Created more follow-up tasks to track identified issues and potential improvements (none of these are blocking the beta release)
    • Updated the documentation page on Wikitech with more accurate information
    • Revised the draft email to announce the feature to Toolforge users
  • Any updates on metrics related to this hypothesis (including baseline, target, or actuals, if applicable)
    • No
  • Any emerging blockers or risks
    • We have less than one week for the evidence collection phase, and this might not be enough to collect enough feedback from users, depending on the level of user engagement.
  • Any unresolved dependencies - do you depend on another team that hasn’t already given you what you need? Are you on the hook to give another team something you aren’t able to give right now?
    • No
  • Have there been any new lessons from the hypothesis?
    • No
  • Have there been any changes to the hypothesis scope or timeline?
    • The hypothesis target date was pushed by another week (new target date: Oct, 23rd) because of an unrelated issue that prevented the team from sending the announcement email this week.

Next steps

  • Pilot/Release phase:
  • Evidence collection phase:
    • measure opt-in rate, evaluate user feedback
fnegri closed this task as Resolved.EditedMon, Nov 2, 5:31 PM
fnegri moved this task from In progress to Done on the tools-platform-team board.

Note: we are experimenting with cross-posting to Phabricator the weekly report that previously was only posted to Asana, where only few people have access.

Summary

  • Hypothesis text
    • If we provide an opt-in email alerting service to notify webservice maintainers by email when their webservices are down, then maintainers sign up to receive alerts for their most critical tools.
  • Progress update on the hypothesis for the week, including if something has shipped
    • Hypothesis lifecycle stage: Evidence collection phase
    • Released the feature to all Toolforge users by deploying T439554
    • Sent the announcement email to the cloud-announce mailing list and updated the documentation page on Wikitech to say that the feature is now available
  • Any updates on metrics related to this hypothesis (including baseline, target, or actuals, if applicable)
    • 22 tools have already opted in to receiving the alerts
    • 8 emails were sent to tool maintainers
  • Any emerging blockers or risks
    • No
  • Any unresolved dependencies - do you depend on another team that hasn’t already given you what you need? Are you on the hook to give another team something you aren’t able to give right now?
    • No
  • Have there been any new lessons from the hypothesis?
    • Unexpected urgent work to address security vulnerabilities forced us to delay the original timeline for this hypothesis
  • Have there been any changes to the hypothesis scope or timeline?
    • We didn't have enough time to collect feedback from users, so we decided to create a new hypothesis in Q2 to promote the alerting feature and to improve it based on user feedback

Next steps

  • None as part of this hypothesis, follow-up work will move to a new hypothesis in Q2.