Hi all,

I'm looking into vetoing notifications[1] in certain circumstances[2]. 
Hoping to gather opinions from the community on if this would be a welcome 
addition to Jenkins core, or is better solved in another way.

I really like the model of QueueTaskDispatcher 
<https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/hudson/model/queue/QueueTaskDispatcher.java>,
 
where anyone can define an Extension that contributes a veto. I think a 
similar model could be useful for notifications. Since notification vetoes 
can be less visible than causes of blockage, I'd also want to log which 
implementation stopped the notification.

Looking through the type hierarchy, it seems like checking for vetoes by 
running through the ExtensionList in BuildStepCompatibilityLayer 
<https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/hudson/tasks/BuildStepCompatibilityLayer.java>
 for 
prebuild and perform would be the place to do this to cover all Notifiers.


   1. from slack-plugin, email-ext-plugin, and mailer-plugin, but would be 
   good for anything extending hudson.tasks.Notifier
   2. external team iterating on Draft PRs and not wanting to create noise


Cheers,
Steve

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-dev/b6f791df-e57a-4f43-bc3b-b910e9b2e187n%40googlegroups.com.

Reply via email to