Fix: add design docs for ResourceTracker (#2909)

* Fix: enhance rt logic and add docs

Signed-off-by: Yin Da <yd219913@alibaba-inc.com>

* Fix: test conflict

Signed-off-by: Yin Da <yd219913@alibaba-inc.com>
This commit is contained in:
Somefive
2021-12-13 19:41:42 +08:00
committed by GitHub
parent c5c664f316
commit a89bb69a62
9 changed files with 184 additions and 12 deletions
@@ -279,7 +279,7 @@ func (r *Reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu
if err := handler.resourceKeeper.StateKeep(ctx); err != nil {
logCtx.Error(err, "Failed to run prevent-configuration-drift")
r.Recorder.Event(app, event.Warning(velatypes.ReasonFailedStateKeep, err))
return r.endWithNegativeCondition(logCtx, app, condition.ReconcileError(err), phase)
app.Status.SetConditions(condition.ErrorCondition("StateKeep", err))
}
if err := garbageCollection(logCtx, handler); err != nil {
logCtx.Error(err, "Failed to run garbage collection")