Skip to content
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

Safely set annotation on datacenter #254

Merged
merged 3 commits into from
Jan 17, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Changelog for Cass Operator, new PRs should update the `main / unreleased` secti
* [FEATURE] Task scheduler support to allow creating tasks that run for each pod in the cluster. The tasks have their own reconciliation process and lifecycle distinct from CassandraDatacenter as well as their own API package.
* [ENHANCEMENT] [#235](https://github.com/k8ssandra/cass-operator/issues/235) Adding AdditionalLabels to add on all resources managed by the operator
* [ENHANCEMENT] [#244](https://github.com/k8ssandra/cass-operator/issues/244) Add ability to skip Cassandra user creation
* [BUGFIX] [#254](https://github.com/k8ssandra/cass-operator/pull/254) Safely set annotation on datacenter in config secret
* [ENHANCEMENT] [#257](https://github.com/k8ssandra/cass-operator/issues/257) Add management-api client method to list schema versions

## v.1.9.0
Expand Down
2 changes: 1 addition & 1 deletion pkg/reconciliation/reconcile_configsecret.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ func (rc *ReconciliationContext) updateConfigHashAnnotation(secret *corev1.Secre
b64Hash := base64.StdEncoding.EncodeToString(hashBytes)

patch := client.MergeFrom(rc.Datacenter.DeepCopy())
rc.Datacenter.Annotations[api.ConfigHashAnnotation] = b64Hash
metav1.SetMetaDataAnnotation(&rc.Datacenter.ObjectMeta, api.ConfigHashAnnotation, b64Hash)

return rc.Client.Patch(rc.Ctx, rc.Datacenter, patch)
}
Expand Down