Closed Bug 1455698 Opened 7 years ago Closed 7 years ago

Don't notify for cancelled tasks

Categories

(Taskcluster :: Services, enhancement)

enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: dustin, Assigned: dustin)

Details

If you enable notification on exception, you currently get notified when a task is cancelled (as that is a kind of exception). This ends up sending a lot of notifications that are usually no good. Could we refine this a little so that "cancel" is treated differently from other exceptions?
We may also want to treat `deadline-exceeded` differently... if we have staging releases that we *don't* cancel, thousands of tasks will hit `deadline-exceeded` at roughly the same time.
Maybe we should add "exception.cancelled", "exception.deadline-exceeded", etc. (for all of the reasons) and users can either use "exception" (all exceptions) or the specific reasons they are interested in.
Jonas points out that this would mean a lot of routes. Perhaps the best thing to do is to extend https://github.com/taskcluster/taskcluster-notify/pull/29 (which just ignores cancel) to also ignore deadline-exceeded.
Or, we could add: task.extra.notify.ignoredReasonResolved = [...] Or just re-think what it is we want to notify one on. If your tasks are expiring by deadline you have a problem, like: - your cron job isn't running - workerType doesn't exist (name was misspelled) - workerType is constantly overloaded - workerType is not spinning up on demand --- Perhaps, it's better to update taskcluster-queue to resolve tasks with: state: exception reasonResolved: 'dependency-unsatisfied' if we reach a state where task.dependencies can't be satisfied. Probably, we would have to update queue.rerunTask, such that dependencies resolved 'dependency-unsatisfied' are also rerun. Just, saying maybe the right place to solve this isn't tc-notify.
Given the current uses of tc-notify (which are pretty minimal), I think it makes sense to make a minimal fix to this, that applies a hard-coded blacklist of reasonResolved that don't result in a notification -- cancelled and deadline-exceeded, for the moment. What you've suggested might be a good additional fix to the queue, but perhaps not something we need right now.
Assignee: nobody → dustin
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Dustin, we've removed almost all our use of tc-notify in bug 145911. There are just a few notify kinds which send ~3 emails per release, and only on success of the underlying dummy builds. Just wanted to check if there were any temporary blocks/fixes which could be undone now.
Flags: needinfo?(dustin)
Whoops, make that bug 1459116.
Yeah, we could certainly remove the blacklist. That happened in bug 1458863.
Flags: needinfo?(dustin)
Component: Integration → Services
You need to log in before you can comment on or make changes to this bug.