Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Webhook (or other alerts) when a build has been clogging up the queue #873

Open
charliegroll opened this issue May 24, 2023 · 7 comments
Open
Labels
enhancement New feature or request

Comments

@charliegroll
Copy link

Problem

Some of our build checks will be pending until someone takes action (approving visual regression snapshot changes, for example). With kodiak, most people tend to "set it to merge and forget it."

Proposed solution

Set a configurable threshold time that publishes to a webhook after that time has passed to notify that the queue is blocked (and maybe repeat the check X times as a reminder?). My team could subscribe to this in Slack (or PagerDuty, or email, etc) so we can unblock our queue before it backs up too much.

@charliegroll charliegroll added the enhancement New feature or request label May 24, 2023
@chdsbd
Copy link
Owner

chdsbd commented May 25, 2023

I think implementation wise this is definitely doable

one workaround that might work in the meantime would be to try this: https://kodiakhq.com/docs/config-reference#mergedont_wait_on_status_checks

Kodiak won’t wait for those PRs that have that status check in a missing state

@chdsbd
Copy link
Owner

chdsbd commented May 25, 2023

@charliegroll Do you use AWS? I was thinking we could allow users to configure an SNS topic in their .kodiak.toml that Kodiak would publish to. I think that's a little easier than trying to build a web hook system

@chdsbd
Copy link
Owner

chdsbd commented May 25, 2023

Another follow up question. When a developer approves a snapshot change, will that GitHub Status Check ever be in the pending state again?

For example, if a developer approves the snapshot changes, and then Kodiak updates the PR branch before merging, would that snapshot GitHub Status Check rerun and temporarily be in the pending state before returning to "success"?

If the status check remains either in a "pending" state or "success" state until there's a developers approval, I think merge.dont_wait_on_status_checks should work

@charliegroll
Copy link
Author

Another follow up question. When a developer approves a snapshot change, will that GitHub Status Check ever be in the pending state again?

For example, if a developer approves the snapshot changes, and then Kodiak updates the PR branch before merging, would that snapshot GitHub Status Check rerun and temporarily be in the pending state before returning to "success"?

I believe you're asking if approval -> update from main -> pending again, in which case I believe that's a possibility, say, if there's a flaky snapshot.

Do you use AWS? I was thinking we could allow users to configure an SNS topic in their .kodiak.toml that Kodiak would publish to. I think that's a little easier than trying to build a web hook system

We theoretically have access to AWS, but I was hoping to set something up directly with slack without an intermediary (plus, we don't generally interact with AWS on my team and would need another team's assistance)

@charliegroll
Copy link
Author

@charliegroll
Copy link
Author

I haven't noticed our queue getting blocked so I think this is working ❤️

@chdsbd
Copy link
Owner

chdsbd commented Jun 22, 2023

That's great to hear!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants