- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 107 for Rand (0.08 sec)
-
cmd/batch-handlers.go
if retryAttempts <= 0 { retryAttempts = batchReplJobDefaultRetries } delay := job.Replicate.Flags.Retry.Delay if delay <= 0 { delay = batchReplJobDefaultRetryDelay } rnd := rand.New(rand.NewSource(time.Now().UnixNano())) hasTags := len(r.Flags.Filter.Tags) != 0 isMetadata := len(r.Flags.Filter.Metadata) != 0
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Aug 29 02:39:48 UTC 2025 - 63.5K bytes - Viewed (0) -
cmd/test-utils_test.go
func getRandomRange(minN, maxN int, seed int64) int { // special value -1 means no explicit seeding. if seed == -1 { return rand.New(rand.NewSource(time.Now().UnixNano())).Intn(maxN-minN) + minN } return rand.New(rand.NewSource(seed)).Intn(maxN-minN) + minN } // Randomizes the order of bytes in the byte array // using Knuth Fisher-Yates shuffle algorithm.
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Aug 29 02:39:48 UTC 2025 - 77K bytes - Viewed (0) -
src/bytes/bytes_test.go
rs = append(rs, r) } } } // Shuffle the runes so that they are not in descending order. // The sort is deterministic since this is used for benchmarks, // which need to be repeatable. rr := rand.New(rand.NewSource(1)) rr.Shuffle(len(rs), func(i, j int) { rs[i], rs[j] = rs[j], rs[i] }) uchars := string(rs) return func(b *testing.B, n int) { buf := bmbuf[0:n] o := copy(buf, uchars)
Registered: Tue Sep 09 11:13:09 UTC 2025 - Last Modified: Mon Jul 28 18:13:58 UTC 2025 - 62.9K bytes - Viewed (0) -
cmd/iam.go
globalServerConfigMu.RLock() s := globalServerConfig globalServerConfigMu.RUnlock() sys.Lock() sys.iamRefreshInterval = iamRefreshInterval sys.Unlock() r := rand.New(rand.NewSource(time.Now().UnixNano())) var ( openidInit bool ldapInit bool authNInit bool authZInit bool ) stsTLSConfig, err := xtls.Lookup(s[config.IdentityTLSSubSys][config.Default])
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Aug 29 02:39:48 UTC 2025 - 75.3K bytes - Viewed (0) -
cmd/erasure-server-pool.go
// so various tasks will be useful bootstrapTrace("initAutoHeal", func() { initAutoHeal(GlobalContext, z) }) // initialize the object layer. defer setObjectLayer(z) r := rand.New(rand.NewSource(time.Now().UnixNano())) attempt := 1 for { var err error bootstrapTrace(fmt.Sprintf("poolMeta.Init: loading pool metadata, attempt: %d", attempt), func() {
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Aug 29 02:39:48 UTC 2025 - 89.1K bytes - Viewed (0) -
tests/migrate_test.go
rand.Seed(time.Now().UnixNano()) rand.Shuffle(len(allModels), func(i, j int) { allModels[i], allModels[j] = allModels[j], allModels[i] }) DB.Migrator().DropTable("user_speaks", "user_friends", "ccc") if err := DB.Migrator().DropTable(allModels...); err != nil { t.Fatalf("Failed to drop table, got error %v", err) }
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Wed Aug 20 04:51:17 UTC 2025 - 65.2K bytes - Viewed (0) -
cmd/xl-storage_test.go
Immediate: false, }) if err != errDiskNotFound { t.Errorf("Expected: \"Drive not found\", got \"%s\"", err) } } // TestXLStorageDeleteFile - Series of test cases construct valid and invalid input data and validates the result and the error response. func TestXLStorageDeleteFile(t *testing.T) { if runtime.GOOS == globalWindowsOSName { t.Skip() } // create xlStorage test setup
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Aug 29 02:39:48 UTC 2025 - 66K bytes - Viewed (0) -
src/bufio/bufio_test.go
t.Errorf("have=%q", written) } } } } } func TestWriterAppend(t *testing.T) { got := new(bytes.Buffer) var want []byte rn := rand.New(rand.NewSource(0)) w := NewWriterSize(got, 64) for i := 0; i < 100; i++ { // Obtain a buffer to append to. b := w.AvailableBuffer() if w.Available() != cap(b) {
Registered: Tue Sep 09 11:13:09 UTC 2025 - Last Modified: Fri Feb 07 01:08:54 UTC 2025 - 51.6K bytes - Viewed (0) -
cmd/object-api-multipart_test.go
import ( "bytes" "context" "fmt" "math/rand" "reflect" "runtime" "strings" "testing" "github.com/dustin/go-humanize" "github.com/minio/minio/internal/config/storageclass" "github.com/minio/minio/internal/hash" "github.com/minio/minio/internal/ioutil" ) // Wrapper for calling NewMultipartUpload tests for both Erasure multiple disks and single node setup.
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Aug 29 02:39:48 UTC 2025 - 89.4K bytes - Viewed (0) -
cmd/xl-storage.go
if !isXL2V1Format(buf) { // This is both legacy and without proper version. if err = xlMeta.AddVersion(fi); err != nil { return err } buf, err = xlMeta.AppendTo(metaDataPoolGet()) defer metaDataPoolPut(buf) if err != nil { return err } } else { if err = xlMeta.Load(buf); err != nil { // Corrupted data, reset and write. xlMeta = xlMetaV2{} }
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Jun 13 11:33:47 UTC 2025 - 91.7K bytes - Viewed (0)