k3s/federation
Kubernetes Submit Queue cd560926bd Merge pull request #36889 from wojtek-t/reuse_fields_and_labels
Automatic merge from submit-queue

Reuse fields and labels

This should significantly reduce memory allocations in apiserver in large cluster.
Explanation:
- every kubelet is refreshing watch every 5-10 minutes (this generally is not causing relist - it just renews watch)
- that means, in 5000-node cluster, we are issuing ~10 watches per second
- since we don't have "watch heartbets", the watch is issued from previously received resourceVersion
- to make some assumption, let's assume pods are evenly spread across pods, and writes for them are evenly spread - that means, that a given kubelet is interested in 1 per 5000 pod changes
- with that assumption, each watch, has to process 2500 (on average) previous watch events
- for each of such even, we are currently computing fields.

This PR is fixing this problem.
2016-12-02 21:49:43 -08:00
..
apis Merge pull request #37532 from smarterclayton/remove_export 2016-12-02 21:11:56 -08:00
client Fix package aliases to follow golang convention 2016-11-30 15:40:50 +08:00
cluster Fixing scripts to bring up federation control plane 2016-11-09 09:47:24 -08:00
cmd add loopback auth defaulting to generic apiserver 2016-11-29 11:02:35 -05:00
deploy Update charts image version. 2016-10-12 00:15:01 -07:00
develop rename build/ to build-tools/ 2016-10-24 14:41:56 -07:00
docs/api-reference generated: remove ExportOptions 2016-11-27 23:21:10 -05:00
manifests Fixing scripts to bring up federation control plane 2016-11-09 09:47:24 -08:00
pkg Bazel update 2016-12-01 15:15:29 +01:00
registry/cluster Cache fields for filtering in watchCache. 2016-11-29 09:48:09 +01:00
Makefile Separate the build recipe in federation Makefile into separate phases. 2016-08-29 14:16:39 -07:00
OWNERS Add colhom to federation OWNERS 2016-06-27 13:16:43 -07:00
README.md Fix doc links in Federation readme 2016-11-07 11:31:08 +00:00

README.md

Cluster Federation

Kubernetes Cluster Federation enables users to federate multiple Kubernetes clusters. Please see the user guide and the admin guide for more details about setting up and using the Cluster Federation.

Building Kubernetes Cluster Federation

Please see the Kubernetes Development Guide for initial setup. Once you have the development environment setup as explained in that guide, you also need to install jq

Building cluster federation artifacts should be as simple as running:

make build

You can specify the docker registry to tag the image using the KUBE_REGISTRY environment variable. Please make sure that you use the same value in all the subsequent commands.

To push the built docker images to the registry, run:

make push

To initialize the deployment run:

(This pulls the installer images)

make init

To deploy the clusters and install the federation components, edit the ${KUBE_ROOT}/_output/federation/config.json file to describe your clusters and run:

make deploy

To turn down the federation components and tear down the clusters run:

make destroy

Ideas for improvement

  1. Continue with destroy phase even in the face of errors.

    The bash script sets set -e errexit which causes the script to exit at the very first error. This should be the default mode for deploying components but not for destroying/cleanup.

Analytics