-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DBZ-7953 Ability to stop DS via debezium.io/stop annotation by scalin…
…g replicas to 0
- Loading branch information
Showing
9 changed files
with
127 additions
and
18 deletions.
There are no files selected for viewing
10 changes: 10 additions & 0 deletions
10
debezium-operator-api/src/main/java/io/debezium/operator/api/model/CommonAnnotations.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/* | ||
* Copyright Debezium Authors. | ||
* | ||
* Licensed under the Apache Software License version 2.0, available at http://www.apache.org/licenses/LICENSE-2.0 | ||
*/ | ||
package io.debezium.operator.api.model; | ||
|
||
public final class CommonAnnotations { | ||
public static final String KEY_DBZ_STOP = "debezium.io/stop"; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
...ator-api/src/main/java/io/debezium/operator/api/model/status/ServerNotReadyCondition.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* | ||
* Copyright Debezium Authors. | ||
* | ||
* Licensed under the Apache Software License version 2.0, available at http://www.apache.org/licenses/LICENSE-2.0 | ||
*/ | ||
package io.debezium.operator.api.model.status; | ||
|
||
public final class ServerNotReadyCondition extends Condition { | ||
|
||
public static final String MESSAGE_TEMPLATE = "Server %s deployment in progress"; | ||
|
||
public ServerNotReadyCondition(String name) { | ||
super(ServerReadyCondition.TYPE, Condition.FALSE, MESSAGE_TEMPLATE.formatted(name)); | ||
} | ||
} |
16 changes: 16 additions & 0 deletions
16
...perator-api/src/main/java/io/debezium/operator/api/model/status/ServerReadyCondition.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
/* | ||
* Copyright Debezium Authors. | ||
* | ||
* Licensed under the Apache Software License version 2.0, available at http://www.apache.org/licenses/LICENSE-2.0 | ||
*/ | ||
package io.debezium.operator.api.model.status; | ||
|
||
public final class ServerReadyCondition extends Condition { | ||
|
||
public static final String TYPE = "Ready"; | ||
private static final String MESSAGE_TEMPLATE = "Server %s is ready"; | ||
|
||
public ServerReadyCondition(String name) { | ||
super(TYPE, Condition.TRUE, MESSAGE_TEMPLATE.formatted(name)); | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
...rator-api/src/main/java/io/debezium/operator/api/model/status/ServerRunningCondition.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* | ||
* Copyright Debezium Authors. | ||
* | ||
* Licensed under the Apache Software License version 2.0, available at http://www.apache.org/licenses/LICENSE-2.0 | ||
*/ | ||
package io.debezium.operator.api.model.status; | ||
|
||
public class ServerRunningCondition extends Condition { | ||
public static final String TYPE = "Running"; | ||
public static final String MESSAGE_TEMPLATE = "Server %s is running"; | ||
|
||
public ServerRunningCondition(String name) { | ||
super(TYPE, Condition.TRUE, MESSAGE_TEMPLATE.formatted(name)); | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
...rator-api/src/main/java/io/debezium/operator/api/model/status/ServerStoppedCondition.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* | ||
* Copyright Debezium Authors. | ||
* | ||
* Licensed under the Apache Software License version 2.0, available at http://www.apache.org/licenses/LICENSE-2.0 | ||
*/ | ||
package io.debezium.operator.api.model.status; | ||
|
||
public class ServerStoppedCondition extends Condition { | ||
public static final String TYPE = "Running"; | ||
public static final String MESSAGE_TEMPLATE = "Server %s is stopped"; | ||
|
||
public ServerStoppedCondition(String name) { | ||
super(TYPE, Condition.FALSE, MESSAGE_TEMPLATE.formatted(name)); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters