Use Kubernetes Configmap to pass the power model parameters to PEAKS plugin
PEAKS plugin requires the power model parameters for each cluster node configured with it.
However, the power model parameters are subjected to change (e.g., increase in the number of CPUs on a node result in change in the power model [ utilization vs. power consumption ]) over time.
Hence we need a mechanism to pass the updated power model parameters of any cluster node.
Configmap can be used to address this issue (a less preferred alternative is to use webhook).
Plan
- Mount a configmap to scheduler pod as volume.
- Configmap contains power model in json.
- Read config map in power model function and unmarshal to json.
Plan
1. Mount a configmap to scheduler pod as volume. 2. Configmap contains power model in json. 3. Read config map in power model function and unmarshal to json.
@fali007 You may want to referrer to the issue https://github.com/sustainable-computing-io/peaks/issues/32 to configure kind cluster for testing your changes.
Associated PR: https://github.com/sustainable-computing-io/scheduler-plugins/pull/9