Skip to content

Commit

Permalink
DBZ-8051: Recreate Kubernetes Strategy
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanvanhuuksloot authored and jcechace committed Jul 11, 2024
1 parent 7a27169 commit a112c5a
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
import io.fabric8.kubernetes.api.model.apps.Deployment;
import io.fabric8.kubernetes.api.model.apps.DeploymentBuilder;
import io.fabric8.kubernetes.api.model.apps.DeploymentSpecBuilder;
import io.fabric8.kubernetes.api.model.apps.DeploymentStrategyBuilder;
import io.javaoperatorsdk.operator.api.reconciler.Context;
import io.javaoperatorsdk.operator.processing.dependent.kubernetes.CRUDKubernetesDependentResource;

Expand Down Expand Up @@ -139,6 +140,9 @@ protected Deployment desired(DebeziumServer primary, Context<DebeziumServer> con
.addToMatchLabels(labels)
.build())
.withTemplate(pod)
.withStrategy(new DeploymentStrategyBuilder()
.withType("Recreate")
.build())
.build())
.build();
}
Expand Down

0 comments on commit a112c5a

Please sign in to comment.