rebase: add replication-lib-utils to go.mod

added github.com/kube-storage/replication-lib-utils
to the vendor directory which is required to avoid
secret logging in GRPC.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
Madhu Rajanna
2021-03-31 13:02:09 +05:30
committed by mergify[bot]
parent da840a70c5
commit ce7f936551
84 changed files with 2800 additions and 1225 deletions

View File

@ -26,6 +26,14 @@ func Bool() bool {
return randSeed%2 == 1
}
// Intn returns a deterministically random integer between 0 and n-1, inclusive.
func Intn(n int) int {
if n <= 0 {
panic("must be positive")
}
return int(randSeed % uint64(n))
}
// randSeed is a best-effort at an approximate hash of the Go binary.
var randSeed = binaryHash()