Skip to content

Commit

Permalink
chore: rename the shards provision/terminate actions to add/remove
Browse files Browse the repository at this point in the history
  • Loading branch information
leon-inf committed Dec 11, 2024
1 parent 248487d commit 602aa5c
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 20 deletions.
8 changes: 4 additions & 4 deletions apis/apps/v1/shardingdefinition_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -186,19 +186,19 @@ type ShardingLifecycleActions struct {
// +optional
PreTerminate *Action `json:"preTerminate,omitempty"`

// Specifies the hook to be executed after a shard's creation.
// Specifies the hook to be executed after a shard added.
//
// Note: This field is immutable once it has been set.
//
// +optional
ShardProvision *Action `json:"shardProvision,omitempty"`
ShardAdd *Action `json:"shardAdd,omitempty"`

// Specifies the hook to be executed prior to terminating a shard.
// Specifies the hook to be executed prior to remove a shard.
//
// Note: This field is immutable once it has been set.
//
// +optional
ShardTerminate *Action `json:"shardTerminate,omitempty"`
ShardRemove *Action `json:"shardRemove,omitempty"`
}

type ShardingSystemAccount struct {
Expand Down
8 changes: 4 additions & 4 deletions apis/apps/v1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions config/crd/bases/apps.kubeblocks.io_shardingdefinitions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -627,9 +627,9 @@ spec:
format: int32
type: integer
type: object
shardProvision:
shardAdd:
description: |-
Specifies the hook to be executed after a shard's creation.
Specifies the hook to be executed after a shard added.
Note: This field is immutable once it has been set.
Expand Down Expand Up @@ -899,9 +899,9 @@ spec:
format: int32
type: integer
type: object
shardTerminate:
shardRemove:
description: |-
Specifies the hook to be executed prior to terminating a shard.
Specifies the hook to be executed prior to remove a shard.
Note: This field is immutable once it has been set.
Expand Down
8 changes: 4 additions & 4 deletions deploy/helm/crds/apps.kubeblocks.io_shardingdefinitions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -627,9 +627,9 @@ spec:
format: int32
type: integer
type: object
shardProvision:
shardAdd:
description: |-
Specifies the hook to be executed after a shard's creation.
Specifies the hook to be executed after a shard added.
Note: This field is immutable once it has been set.
Expand Down Expand Up @@ -899,9 +899,9 @@ spec:
format: int32
type: integer
type: object
shardTerminate:
shardRemove:
description: |-
Specifies the hook to be executed prior to terminating a shard.
Specifies the hook to be executed prior to remove a shard.
Note: This field is immutable once it has been set.
Expand Down
8 changes: 4 additions & 4 deletions docs/developer_docs/api-reference/cluster.md
Original file line number Diff line number Diff line change
Expand Up @@ -10675,7 +10675,7 @@ until the PreTerminate action has completed successfully.</p>
</tr>
<tr>
<td>
<code>shardProvision</code><br/>
<code>shardAdd</code><br/>
<em>
<a href="#apps.kubeblocks.io/v1.Action">
Action
Expand All @@ -10684,13 +10684,13 @@ Action
</td>
<td>
<em>(Optional)</em>
<p>Specifies the hook to be executed after a shard&rsquo;s creation.</p>
<p>Specifies the hook to be executed after a shard added.</p>
<p>Note: This field is immutable once it has been set.</p>
</td>
</tr>
<tr>
<td>
<code>shardTerminate</code><br/>
<code>shardRemove</code><br/>
<em>
<a href="#apps.kubeblocks.io/v1.Action">
Action
Expand All @@ -10699,7 +10699,7 @@ Action
</td>
<td>
<em>(Optional)</em>
<p>Specifies the hook to be executed prior to terminating a shard.</p>
<p>Specifies the hook to be executed prior to remove a shard.</p>
<p>Note: This field is immutable once it has been set.</p>
</td>
</tr>
Expand Down

0 comments on commit 602aa5c

Please sign in to comment.