-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: support parameters api for wesql
- Loading branch information
Showing
9 changed files
with
217 additions
and
176 deletions.
There are no files selected for viewing
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
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 was deleted.
Oops, something went wrong.
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,17 @@ | ||
apiVersion: parameters.kubeblocks.io/v1alpha1 | ||
kind: ParameterDrivenConfigRender | ||
metadata: | ||
name: {{ include "apecloud-mysql.wescalePCRName" . }} | ||
labels: | ||
{{- include "apecloud-mysql.labels" . | nindent 4 }} | ||
spec: | ||
componentDef: {{ include "apecloud-mysql.cmpdNameWescale" . }} | ||
parametersDefs: | ||
- {{ include "apecloud-mysql.wescaleParamsDefName" . }} | ||
|
||
configs: | ||
- name: vtgate.cnf | ||
fileFormatConfig: | ||
format: ini | ||
iniConfig: | ||
sectionName: vtgate |
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,25 @@ | ||
apiVersion: parameters.kubeblocks.io/v1alpha1 | ||
kind: ParameterDrivenConfigRender | ||
metadata: | ||
name: {{ include "apecloud-mysql.wesqlPCRName" . }} | ||
labels: | ||
{{- include "apecloud-mysql.labels" . | nindent 4 }} | ||
spec: | ||
componentDef: {{ include "apecloud-mysql.cmpdNameApecloudMySQL" . }} | ||
parametersDefs: | ||
- {{ include "apecloud-mysql.wesqlParamsDefName" . }} | ||
- {{ include "apecloud-mysql.wesqlVttabletParamsDefName" . }} | ||
|
||
configs: | ||
- name: my.cnf | ||
fileFormatConfig: | ||
format: ini | ||
iniConfig: | ||
sectionName: mysqld | ||
reRenderResourceTypes: | ||
- vscale | ||
- name: vttablet.cnf | ||
fileFormatConfig: | ||
format: ini | ||
iniConfig: | ||
sectionName: vttablet |
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,45 @@ | ||
{{- $vtgatecc := .Files.Get "config/mysql-scale-vtgate-config-effect-scope.yaml" | fromYaml }} | ||
apiVersion: parameters.kubeblocks.io/v1alpha1 | ||
kind: ParametersDefinition | ||
metadata: | ||
name: {{ include "apecloud-mysql.wescaleParamsDefName" . }} | ||
labels: | ||
{{- include "apecloud-mysql.labels" . | nindent 4 }} | ||
spec: | ||
reloadAction: | ||
autoTrigger: | ||
processName: vtgate | ||
|
||
fileName: vtgate.cnf | ||
parametersSchema: | ||
topLevelKey: VtGateParameter | ||
|
||
cue: |- | ||
{{- .Files.Get "config/mysql-scale-vtgate-config-constraint.cue" | nindent 6 }} | ||
## define static parameter list | ||
{{- if hasKey $vtgatecc "staticParameters" }} | ||
staticParameters: | ||
{{- $params := get $vtgatecc "staticParameters" }} | ||
{{- range $params }} | ||
- {{ . }} | ||
{{- end }} | ||
{{- end}} | ||
|
||
## define dynamic parameter list | ||
{{- if hasKey $vtgatecc "dynamicParameters" }} | ||
dynamicParameters: | ||
{{- $params := get $vtgatecc "dynamicParameters" }} | ||
{{- range $params }} | ||
- {{ . }} | ||
{{- end }} | ||
{{- end}} | ||
|
||
## define immutable parameter list, this feature is not currently supported. | ||
{{- if hasKey $vtgatecc "immutableParameters" }} | ||
immutableParameters: | ||
{{- $params := get $vtgatecc "immutableParameters" }} | ||
{{- range $params }} | ||
- {{ . }} | ||
{{- end }} | ||
{{- end}} |
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,45 @@ | ||
{{- $vttabletcc := .Files.Get "config/mysql-scale-vttablet-config-effect-scope.yaml" | fromYaml }} | ||
apiVersion: parameters.kubeblocks.io/v1alpha1 | ||
kind: ParametersDefinition | ||
metadata: | ||
name: {{ include "apecloud-mysql.wesqlVttabletParamsDefName" . }} | ||
|
||
labels: | ||
{{- include "apecloud-mysql.labels" . | nindent 4 }} | ||
spec: | ||
reloadAction: | ||
autoTrigger: | ||
processName: vttablet | ||
|
||
fileName: vttablet.cnf | ||
parametersSchema: | ||
topLevelKey: VtTabletParameter | ||
cue: |- | ||
{{- .Files.Get "config/mysql-scale-vttablet-config-constraint.cue" | nindent 6 }} | ||
## define static parameter list | ||
{{- if hasKey $vttabletcc "staticParameters" }} | ||
staticParameters: | ||
{{- $params := get $vttabletcc "staticParameters" }} | ||
{{- range $params }} | ||
- {{ . }} | ||
{{- end }} | ||
{{- end}} | ||
|
||
## define dynamic parameter list | ||
{{- if hasKey $vttabletcc "dynamicParameters" }} | ||
dynamicParameters: | ||
{{- $params := get $vttabletcc "dynamicParameters" }} | ||
{{- range $params }} | ||
- {{ . }} | ||
{{- end }} | ||
{{- end}} | ||
|
||
## define immutable parameter list, this feature is not currently supported. | ||
{{- if hasKey $vttabletcc "immutableParameters" }} | ||
immutableParameters: | ||
{{- $params := get $vttabletcc "immutableParameters" }} | ||
{{- range $params }} | ||
- {{ . }} | ||
{{- end }} | ||
{{- end}} |
Oops, something went wrong.