-
Notifications
You must be signed in to change notification settings - Fork 175
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
chore: update the group of the BackupPolicyTemplate to "dataprotection" #8203
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #8203 +/- ##
==========================================
+ Coverage 61.24% 61.63% +0.38%
==========================================
Files 348 348
Lines 40184 40615 +431
==========================================
+ Hits 24611 25033 +422
- Misses 13333 13367 +34
+ Partials 2240 2215 -25
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
23b569d
to
b81bcfa
Compare
return transformBackupPolicyAndSchedule(bpt, compSpec, componentName, isSharding, false) | ||
} | ||
|
||
for i := range r.Cluster.Spec.ComponentSpecs { |
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.
Can we move all the logic into BackupPolicyTemplateReconciler?
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 backupPolicy
and backupScheduled
are reconciled by the cluster.spec.backup and componentSpecs/shardingSpecs. if move it to BackupPolicyTemplateReconciler, bpt controller will watch the changes of the cluster and handle the logic for all related clusters .
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 backup policy needs a mechanism or the API to bind to the cluster in a loosely coupled way. For example, referring to Prometheus, the backup policy can define an annotation and well-defined value, so that the cluster only needs to serialize the necessary backup information to this annotation in the defined format, and the backup policy controller can generate the object for it automatically.
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.
When using a BPT (Backup Policy Template) controller, every time there is a change in the cluster, the corresponding BPT will reconcile all related clusters to synchronize the backup policies and schedules. If there are many clusters, this can keep the controller very busy, potentially causing blocks and delaying reconciliations. Prometheus, on the other hand, periodically pulls all metrics with the specified annotations, which is a reasonable approach.
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.
Please resolve conflicts.
553b25d
to
5af29e1
Compare
5af29e1
to
a68b94d
Compare
No description provided.