Skip to content

Commit

Permalink
Add MySQL Multi Primary Option in Group Replication Mode (#1348)
Browse files Browse the repository at this point in the history
Signed-off-by: Ashraful Haque Tani <[email protected]>
  • Loading branch information
AshrafulHaqueToni authored Nov 19, 2024
1 parent 0cfb57e commit 2fa3548
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions apis/kubedb/v1/mysql_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,12 @@ const (
MySQLModeSemiSync MySQLMode = "SemiSync"
)

// +kubebuilder:validation:Enum=Single-Primary
// +kubebuilder:validation:Enum=Single-Primary;Multi-Primary
type MySQLGroupMode string

const (
MySQLGroupModeSinglePrimary MySQLGroupMode = "Single-Primary"
// MySQLGroupModeMultiPrimary MySQLGroupMode = "Multi-Primary"
MySQLGroupModeMultiPrimary MySQLGroupMode = "Multi-Primary"
)

// Mysql defines a Mysql database.
Expand Down
4 changes: 2 additions & 2 deletions apis/kubedb/v1alpha2/mysql_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,12 @@ const (
MySQLModeSemiSync MySQLMode = "SemiSync"
)

// +kubebuilder:validation:Enum=Single-Primary
// +kubebuilder:validation:Enum=Single-Primary;Multi-Primary
type MySQLGroupMode string

const (
MySQLGroupModeSinglePrimary MySQLGroupMode = "Single-Primary"
// MySQLGroupModeMultiPrimary MySQLGroupMode = "Multi-Primary"
MySQLGroupModeMultiPrimary MySQLGroupMode = "Multi-Primary"
)

// Mysql defines a Mysql database.
Expand Down
4 changes: 4 additions & 0 deletions crds/kubedb.com_mysqls.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4815,6 +4815,7 @@ spec:
default: Single-Primary
enum:
- Single-Primary
- Multi-Primary
type: string
name:
type: string
Expand All @@ -4825,6 +4826,7 @@ spec:
default: Single-Primary
enum:
- Single-Primary
- Multi-Primary
type: string
router:
properties:
Expand Down Expand Up @@ -12478,6 +12480,7 @@ spec:
default: Single-Primary
enum:
- Single-Primary
- Multi-Primary
type: string
name:
type: string
Expand All @@ -12488,6 +12491,7 @@ spec:
default: Single-Primary
enum:
- Single-Primary
- Multi-Primary
type: string
router:
properties:
Expand Down

0 comments on commit 2fa3548

Please sign in to comment.