Documentation
¶
Overview ¶
Package hash allows the user to get a hash number for a given Kubernetes object. This is useful to detect when a derived resource need to be changed too.
The code in this package is adapted from:
https://github.com/kubernetes/kubernetes/blob/master/pkg/util/hash/hash.go // wokeignore:rule=master https://github.com/kubernetes/kubernetes/blob/ea0764452222146c47ec826977f49d7001b0ea8c/
pkg/controller/controller_utils.go#L1189
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ComputeHash ¶
ComputeHash returns a hash value calculated from pod template and a collisionCount to avoid hash collision. The hash will be safe encoded to avoid bad words.
func DeepHashObject ¶
DeepHashObject writes specified object to hash using the spew library which follows pointers and prints actual values of the nested objects ensuring the hash does not change when a pointer changes.
Types ¶
This section is empty.