kube-router icon indicating copy to clipboard operation
kube-router copied to clipboard

Support traffic shaping in CNI

Open kvaps opened this issue 4 years ago • 3 comments

k8s 1.12 added a support for traffic shaping: kubernetes/kubernetes#63194 and kubernetes/community#1893. We should support it in the CNI plugin.

kvaps avatar Jul 15 '20 13:07 kvaps

@kvaps What is your expectation from kube-router? Update the manifests with bandwidth plugin? I belive you should be able to use traffic shaping CNI https://github.com/containernetworking/plugins/tree/master/plugins/meta/bandwidth just by chaining just as how portmap is used.

murali-reddy avatar Jul 16 '20 01:07 murali-reddy

Hi, if I remember it correct the mentioned bandwidth plugin has no tight integration with Kubernetes, and does not allow to set the bandwidth limit per pod via annotations.

kvaps avatar Jul 16 '20 05:07 kvaps

kube-router currently only supports configuring upstream CNI plugins. If there is a way that we can help configure an already existing CNI plugin to support traffic shaping, that might be do-able, but given the breadth that kube-router already spans and the difficulty supporting that breadth I think that it would be a bad idea to add CNI plugin development to our existing stack.

If you can give some concrete details about what would be involved in configuring an already existing CNI plugin to do this shaping then I'd be willing to look into scheduling the work after the 1.2 performance release. Otherwise we'll probably end up closing this issue as something that kube-router cannot support at this time.

aauren avatar Aug 31 '20 16:08 aauren

Closing as stale.

aauren avatar Oct 31 '22 04:10 aauren