Adding a watcher for each (named) object in spec.syncItems would allow Espejo to update/recreate an object immediately upon changes. On accidential deletions they would be recreated/reconciled. This would also remove the need to regularly reconcile for nothing (when no object changed)
Questions:
Performance: Is it feasible to add a watcher for each object? Does it consume much memory/CPU compared to reconciling regularly? Do we generally watch the Kind of object and filter by name?
Link: How do we link an update event back to a specific SyncConfig? Labels, Annotations, OwnerReference?
What if multiple SyncConfigs manage the same set of Objects? Will there be a loop, how can it be broken?
Adding a watcher for each (named) object in
spec.syncItems
would allow Espejo to update/recreate an object immediately upon changes. On accidential deletions they would be recreated/reconciled. This would also remove the need to regularly reconcile for nothing (when no object changed)Questions: