- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 42 for newSource (0.19 sec)
-
cmd/dynamic-timeouts_test.go
// Race test. timeout := newDynamicTimeout(time.Second, time.Millisecond) var wg sync.WaitGroup for i := 0; i < runtime.GOMAXPROCS(0); i++ { wg.Add(1) rng := rand.New(rand.NewSource(int64(i))) go func() { defer wg.Done() for i := 0; i < 100; i++ { for j := 0; j < 100; j++ { timeout.LogSuccess(time.Duration(float64(time.Second) * rng.Float64())) }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Oct 14 10:08:40 UTC 2022 - 5.4K bytes - Viewed (0) -
cmd/local-locker_test.go
} if len(l.lockUID) != 0 { t.Fatalf("lockUID len, got %d, want %d + %d", len(l.lockUID), 0, 0) } } func Test_localLocker_expireOldLocksExpire(t *testing.T) { rng := rand.New(rand.NewSource(0)) quorum := 0 // Numbers of unique locks for _, locks := range []int{100, 1000, 1e6} { if testing.Short() && locks > 100 { continue } t.Run(fmt.Sprintf("%d-locks", locks), func(t *testing.T) {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Jul 24 10:24:01 UTC 2024 - 11.9K bytes - Viewed (0) -
cmd/erasure-metadata-utils_test.go
testShuffleDisks(t, z) } func Test_hashOrder(t *testing.T) { for x := 1; x < 17; x++ { t.Run(fmt.Sprintf("%d", x), func(t *testing.T) { var first [17]int rng := rand.New(rand.NewSource(0)) var tmp [16]byte rng.Read(tmp[:]) prefix := hex.EncodeToString(tmp[:]) for i := 0; i < 10000; i++ { rng.Read(tmp[:])
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Jan 18 07:03:17 UTC 2024 - 7.4K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/cache/DiskLruCacheTest.kt
setUp(parameters.first, parameters.second) val creator = cache.edit("k1")!! creator.setString(0, "ABC") creator.setString(1, "DE") assertThat(creator.newSource(0)).isNull() assertThat(creator.newSource(1)).isNull() creator.commit() val snapshot = cache["k1"]!! snapshot.assertValue(0, "ABC") snapshot.assertValue(1, "DE") } @ParameterizedTest
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Apr 15 14:55:09 UTC 2024 - 75.8K bytes - Viewed (0) -
cmd/site-replication-utils.go
peerResyncMap: make(map[string]resyncState), } go s.save(ctx) go s.init(ctx) return &s } // init site resync metrics func (sm *siteResyncMetrics) init(ctx context.Context) { r := rand.New(rand.NewSource(time.Now().UnixNano())) // Run the site resync metrics load in a loop for { if err := sm.load(ctx, newObjectLayerFn()); err == nil { <-ctx.Done() return }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Jan 18 07:03:17 UTC 2024 - 8.9K bytes - Viewed (0) -
cmd/object-api-utils.go
return hosts } // returns an online host (and corresponding port) from a slice of DNS records func getHostFromSrv(records []dns.SrvRecord) (host string) { hosts := getHostsSlice(records) rng := rand.New(rand.NewSource(time.Now().UTC().UnixNano())) var d net.Dialer var retry int for retry < len(hosts) { ctx, cancel := context.WithTimeout(GlobalContext, 300*time.Millisecond) host = hosts[rng.Intn(len(hosts))]
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 08 15:29:58 UTC 2024 - 37.1K bytes - Viewed (0) -
cmd/batch-rotate.go
retryAttempts = batchKeyRotateJobDefaultRetries } delay := job.KeyRotate.Flags.Retry.Delay if delay <= 0 { delay = batchKeyRotateJobDefaultRetryDelay } rnd := rand.New(rand.NewSource(time.Now().UnixNano())) selectObj := func(info FileInfo) (ok bool) { if r.Flags.Filter.OlderThan > 0 && time.Since(info.ModTime) < r.Flags.Filter.OlderThan {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Sep 18 17:59:03 UTC 2024 - 14.7K bytes - Viewed (0) -
cmd/tier.go
Tiers: make(map[string]madmin.TierConfig), } } func (config *TierConfigMgr) refreshTierConfig(ctx context.Context, objAPI ObjectLayer) { const tierCfgRefresh = 15 * time.Minute r := rand.New(rand.NewSource(time.Now().UnixNano())) randInterval := func() time.Duration { return time.Duration(r.Float64() * 5 * float64(time.Second)) } // To avoid all MinIO nodes reading the tier config object at the same // time.
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Sep 12 20:44:05 UTC 2024 - 15.7K bytes - Viewed (0) -
cmd/server-main.go
return } globalTrace.Publish(info) } func initServerConfig(ctx context.Context, newObject ObjectLayer) error { t1 := time.Now() r := rand.New(rand.NewSource(time.Now().UnixNano())) for { select { case <-ctx.Done(): // Retry was canceled successfully. return fmt.Errorf("Initializing sub-systems stopped gracefully %w", ctx.Err()) default: }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Sep 24 21:50:11 UTC 2024 - 35.2K bytes - Viewed (1) -
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 Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Oct 18 15:32:09 UTC 2024 - 62.2K bytes - Viewed (0)