-
Notifications
You must be signed in to change notification settings - Fork 1.5k
extend the EntityOperator, CruiseControl and KafkaExporter to support PDB #11699
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
Changes from all commits
799c185
e96c39e
181aab6
348be52
fe24555
fe3c7ba
31801ff
5984b19
f17daf5
b0e6b47
35a3a53
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -20,11 +20,13 @@ | |
| import io.fabric8.kubernetes.api.model.networking.v1.NetworkPolicy; | ||
| import io.fabric8.kubernetes.api.model.networking.v1.NetworkPolicyIngressRule; | ||
| import io.fabric8.kubernetes.api.model.networking.v1.NetworkPolicyPeer; | ||
| import io.fabric8.kubernetes.api.model.policy.v1.PodDisruptionBudget; | ||
| import io.strimzi.api.kafka.model.common.JvmOptions; | ||
| import io.strimzi.api.kafka.model.common.metrics.JmxPrometheusExporterMetrics; | ||
| import io.strimzi.api.kafka.model.common.metrics.StrimziMetricsReporter; | ||
| import io.strimzi.api.kafka.model.common.template.DeploymentTemplate; | ||
| import io.strimzi.api.kafka.model.common.template.InternalServiceTemplate; | ||
| import io.strimzi.api.kafka.model.common.template.PodDisruptionBudgetTemplate; | ||
| import io.strimzi.api.kafka.model.common.template.PodTemplate; | ||
| import io.strimzi.api.kafka.model.kafka.Kafka; | ||
| import io.strimzi.api.kafka.model.kafka.KafkaClusterSpec; | ||
|
|
@@ -140,6 +142,7 @@ public class CruiseControl extends AbstractModel implements SupportsMetrics, Sup | |
| private DeploymentTemplate templateDeployment; | ||
| private PodTemplate templatePod; | ||
| private InternalServiceTemplate templateService; | ||
| private PodDisruptionBudgetTemplate templatePodDisruptionBudget; | ||
|
|
||
| private static final Map<String, String> DEFAULT_POD_LABELS = new HashMap<>(); | ||
| static { | ||
|
|
@@ -235,6 +238,7 @@ public static CruiseControl fromCrd( | |
| result.templateService = template.getApiService(); | ||
| result.templateServiceAccount = template.getServiceAccount(); | ||
| result.templateContainer = template.getCruiseControlContainer(); | ||
| result.templatePodDisruptionBudget = template.getPodDisruptionBudget(); | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Yes, we were ignoring it. It looks like I added the template years ago but never added the spec or reconciliation bits.
I can confirm it is not currently supported for Cruise Control. |
||
| } | ||
|
|
||
| return result; | ||
|
|
@@ -542,4 +546,19 @@ public ConfigMap generateConfigMap(MetricsAndLogging metricsAndLogging) { | |
| configMapData | ||
| ); | ||
| } | ||
| /** | ||
| * Generates the PodDisruptionBudget for Cruise Control | ||
| * | ||
| * @return The PodDisruptionBudget for Cruise Control | ||
| */ | ||
| public PodDisruptionBudget generatePodDisruptionBudget() { | ||
| return PodDisruptionBudgetUtils.createCustomControllerPodDisruptionBudget( | ||
| componentName, | ||
| namespace, | ||
| labels, | ||
| ownerReference, | ||
| templatePodDisruptionBudget, | ||
| 1 | ||
| ); | ||
| } | ||
| } | ||
Uh oh!
There was an error while loading. Please reload this page.