kubernetes/pkg/scheduler/algorithm/predicates
Jonathan Basseri f5ab6d5ad4 [PATCH] Fix equiv. cache invalidation of Node condition.
Equivalence cache for CheckNodeConditionPred becomes invalid when
Node.Spec.Unschedulable changes. This can happen even if
Node.Status.Conditions does not change, so move the logic around.

This logic is covered by integration test
"test/integration/scheduler".TestUnschedulableNodes but equivalence
cache is currently skipped when test pods have no OwnerReference.

Add benchmark for equivalence hashing.

Change equivalence hash function.

This changes the equivalence class hashing function to use as inputs all
the Pod fields which are read by FitPredicates. Before we used a
combination of OwnerReference and PersistentVolumeClaim info, which was
a close approximation. The new method ensures that hashing remains
correct regardless of controller behavior.

The PVCSet field can be removed from equivalencePod because it is
implicitly included in the Volume list.

Tests are now broken.

Move equivalence class hash code.

This moves the equivalence hashing code from
algorithm/predicates/utils.go to core/equivalence_cache.go.

In the process, making the hashing function and hashing function factory
both injectable dependencies is removed.

Fix equivalence cache hash tests.

Co-authored-by: Jonathan Basseri <misterikkit@google.com>
Co-authored-by: Harry Zhang <resouer@gmail.com>
2018-03-04 13:02:28 -08:00
..
BUILD [PATCH] Fix equiv. cache invalidation of Node condition. 2018-03-04 13:02:28 -08:00
error.go Fix golint errors in pkg/scheduler based on golint check 2018-02-08 15:22:47 +08:00
metadata_test.go Fix golint errors in pkg/scheduler based on golint check 2018-02-08 15:22:47 +08:00
metadata.go Support cluster-level extended resources in kubelet and kube-scheduler 2018-02-27 17:25:30 -08:00
predicates_test.go Support cluster-level extended resources in kubelet and kube-scheduler 2018-02-27 17:25:30 -08:00
predicates.go Merge pull request #60386 from k82cn/k8s_60163 2018-03-02 03:41:50 -08:00
testing_helper.go Fix golint errors in pkg/scheduler based on golint check 2018-02-08 15:22:47 +08:00
utils_test.go Refactor HostIP predicate algorithm 2018-01-08 17:10:21 -08:00
utils.go [PATCH] Fix equiv. cache invalidation of Node condition. 2018-03-04 13:02:28 -08:00