-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EVEREST-1874 | support volume expansion for PXC #688
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
|
||
// StorageClassSupportsVolumeExpansion returns true if the storage class supports volume expansion. | ||
// If className is unspecified, uses the default storage class | ||
func StorageClassSupportsVolumeExpansion(c client.Client, ctx context.Context, className *string) (bool, error) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [golangci-lint] reported by reviewdog 🐶
context-as-argument: context.Context should be the first parameter of a function (revive)
return *storageClass.AllowVolumeExpansion, nil | ||
} | ||
|
||
func getStorageClassOrDefault(c client.Client, ctx context.Context, scName *string) (*storagev1.StorageClass, error) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [golangci-lint] reported by reviewdog 🐶
context-as-argument: context.Context should be the first parameter of a function (revive)
@@ -73,6 +75,63 @@ func (p *applier) AllowUnsafeConfig() { | |||
} | |||
} | |||
|
|||
func configureStorage( | |||
c client.Client, | |||
ctx context.Context, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [golangci-lint] reported by reviewdog 🐶
context-as-argument: context.Context should be the first parameter of a function (revive)
storageClassDefaultAnnotation = "storageclass.kubernetes.io/is-default-class" | ||
) | ||
|
||
// StorageClassSupportsVolumeExpansion returns true if the storage class supports volume expansion. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [golangci-lint] reported by reviewdog 🐶
Comment should end in a period (godot)
return &sc, nil | ||
} | ||
} | ||
return nil, fmt.Errorf("no default storage class found") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [golangci-lint] reported by reviewdog 🐶
fmt.Errorf can be replaced with errors.New (perfsprint)
CHANGE DESCRIPTION
Problem:
EVEREST-0
Short explanation of the problem.
Related pull requests
Cause:
Short explanation of the root cause of the issue if applicable.
Solution:
Short explanation of the solution we are providing with this PR.
CHECKLIST
Helm chart
Jira
Tests