Hi Devs, Kubernetes community is now working on implementing $subject. According to [1] scaling can be done based on Traffic, Predictive Analysis and Arbitrary Data.
Autoscaling policies can be defined to configure min/max values. Compared to the Autoscaling policy we have in Stratos this has been designed in a generic way to be able to use with different scaling factors [2]. Autoscaling algorithm is as follows: *The autoscaler will be implemented as a control loop. It will periodically (e.g.: every 1 minute) query pods described by Status.PodSelector of Scale subresource, and check their average CPU or memory usage from the last 1 minute (there will be API on master for this purpose, see #11951. Then, it will compare the current CPU or memory consumption with the Target, and adjust the count of the Scale if needed to match the target (preserving condition: MinCount <= Count <= MaxCount).* *The target number of pods will be calculated from the following formula:* *TargetNumOfPods =ceil(sum(CurrentPodsConsumption) / Target)* Read following links for more information: [1] https://github.com/kubernetes/kubernetes/blob/master/docs/proposals/autoscaling.md [2] https://github.com/kubernetes/kubernetes/blob/master/docs/proposals/horizontal-pod-autoscaler.md Thanks -- Imesh Gunaratne Senior Technical Lead, WSO2 Committer & PMC Member, Apache Stratos