kodiak icon indicating copy to clipboard operation
kodiak copied to clipboard

Code Freeze via the Dashboard

Open charliegroll opened this issue 3 years ago • 3 comments

It'd be great if we could pause the queue and halt all kodiak merges via the dashboard (ideally per repo, but per org would be a good start). If we have an ongoing incident and 5 merges queued up, it'd be great to not allow any to merge. On top of that, we would need to still be able to cut the line/deploy during an incident, but I assume prioritized merges would fit that bill.

charliegroll avatar Mar 09 '22 17:03 charliegroll

Hey @charliegroll, this sounds like a nice enhancement!

Prioritized merges should help during an incident. When you add the priority label to a PR, if there is a PR being merged by Kodiak, Kodiak will continue to merge that PR and then pickup the prioritized PR afterwards. Basically Kodiak doesn't cancel the existing merge.

To halt all merges, you might be able to use this GitHub App: https://www.mergefreeze.com/ I haven't used it, so I can't really speak to how well it works, but I've seen other organizations using it.

I think implementing this feature in Kodiak is doable. We'd need to update the Dashboard (UI and API) to store some state about a merge freeze for a repository in the GitHub Bot's Redis instance. Then we could update the bot to check that Redis state when evaluating PRs.

So this feature would touch all parts of the app, but it isn't too complicated from my POV. It's actually pretty similar to how the paywall works at the moment.

chdsbd avatar Mar 09 '22 22:03 chdsbd

@charliegroll Do you think the mergefreeze app would work for your use case or do you think this would be better as a part of Kodiak?

chdsbd avatar Mar 15 '22 23:03 chdsbd

@chdsbd that looks like it would work for our use case, thanks for the tip!

charliegroll avatar Mar 23 '22 19:03 charliegroll