-
Notifications
You must be signed in to change notification settings - Fork 0
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
Added Resize Settings and Resize Operations #551
Conversation
4f36fc4
to
e624381
Compare
64a1371
to
a07fcb3
Compare
pkg/models/errors.go
Outdated
@@ -61,4 +61,5 @@ var ( | |||
ErrPrivateLinkSupportedOnlyForSingleDC = errors.New("private link is only supported for a single data centre") | |||
ErrPrivateLinkSupportedOnlyForAWS = errors.New("private link is supported only for an AWS cloud provider") | |||
ErrImmutableSpec = errors.New("resource specification is immutable") | |||
ErrOnlySingleConcurrentResizeAvailable = errors.New("only 1 concurrent resize is allowed") |
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.
Maybe we should change message from "only 1 concurrent resize is allowed" to "only single concurrent resize is allowed"
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.
Changed
Makefile
Outdated
docker-build: manifests generate test ## Build docker image with the manager. | ||
docker-build: manifests generate #test ## Build docker image with the manager. |
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.
Revert this change please
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.
Fixed
pkg/instaclustr/client.go
Outdated
fmt.Printf("CASSANDRA SPEC UPDATE: %s\n", data) | ||
|
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.
Remove this code please
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.
Removed
8039cfa
to
1c89af8
Compare
@@ -181,9 +183,10 @@ func (cs *CassandraSpec) HasRestore() bool { | |||
return false | |||
} | |||
|
|||
func (cs *CassandraSpec) NewDCsUpdate() models.CassandraClusterAPIUpdate { | |||
func (cs *CassandraSpec) ToClusterUpdate() models.CassandraClusterAPIUpdate { |
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.
func (cs *CassandraSpec) ToClusterUpdate() models.CassandraClusterAPIUpdate { | |
func (cs *CassandraSpec) DCsUpdateToInstAPI() models.CassandraClusterAPIUpdate { |
The Instaclustr APIv2 has multiple endpoints for updating various fields in a cluster specification. One of them is ClusterSettings
. Therefore, I suggest specifically naming the update fields.
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.
Fixed
apis/clusters/v1beta1/structs.go
Outdated
return iRS | ||
} | ||
|
||
type ReplaceOperationInfoV2 struct { |
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.
Just call it ReplaceOperation
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.
Renamed
pkg/instaclustr/client.go
Outdated
@@ -208,7 +208,7 @@ func (c *Client) GetRedisUser(id string) (*models.RedisUser, error) { | |||
return userRedis, nil | |||
} | |||
|
|||
func (c *Client) UpdateRedis(id string, r *models.RedisDataCentreUpdate) error { | |||
func (c *Client) UpdateRedis(id string, r *models.RedisUpdate) 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.
The message with different update fields also applies to this part of the code
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.
Fixed
… operations to its statuses
Done: