Rework internal resource trackers
distorhead opened this issue · 0 comments
distorhead commented
The problem: there is a lot of repeated code in each tracker in pkg/tracker
, it is:
- hard to maintain this code and fix bugs;
- hard to add new trackers for custom resources, because a lot of code need to be copied.
Solution: rework pkg/tracker
, so that:
- it uses dynamic kubernetes client;
- it implements some common base resource with typical operations needed to implement any concrete resource tracker;
- it does not mix representational logic with status reporting mechanics (status-indicators in the current implementation should not be implemented in the resource trackers, but instead should be implemented at the multitracker level).
1st step includes:
- implementing new framework to build resource trackers;
- implementing Deployment tracker on top of such framework;
- implementing compatibility adapter for Deployment so that new tracker can be used in the current version of multitracker.