RocketChat / helm-charts

Repository for RocketChat helm charts
37 stars 67 forks source link

[Feature] Make PodDisruptionBudget optional even if replicas > 1 #36

Closed ccremer closed 2 years ago

ccremer commented 2 years ago

Currently a PodDisruptionBudget always gets deployed if replicaCount is greater than 1. However, there's no way to disable this.

While PodDisruptionBudgets certainly have their reasons for existence, in our field we rather made "mixed" experiences. PDBs sometimes interfere with regular scheduled cluster maintenances, where every node is being drained and rebooted. PDBs often block or delay such reboots, so for our use cases a replicaCount of 2 or more with AntiAffinity is sufficient.

I propose an additional parameter like podDisruptionBudget.enabled, which is by default true. However, the condition to deploy a PDB is logical AND with replicaCount being greater than 1 (since deploying PDB with just 1 replica is even more "harmful" for node drains). That way we avoid breaking changes while still being able to disable a PDB.

What do you think? If this is acceptable, would work on this on your own or would you be interested in a PR?

ccremer commented 2 years ago

Any comments here?

prppedro commented 2 years ago

@ccremer, I've just added that flag you suggested — podDisruptionBudget.enabled — and a conditional clause on PDB's template. Let me know if it works for you. It, however, defaults to true, for now.

ccremer commented 2 years ago

Hi @prppedro Much appreciated. We'll be awaiting a new release then.