Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 294 for Now (0.14 sec)

  1. cmd/data-scanner_test.go

    	}
    
    	bucket := "bucket"
    	obj := "obj-1"
    	now := time.Now()
    	meta := BucketMetadata{
    		Name:                      bucket,
    		Created:                   now,
    		LifecycleConfigXML:        lcXML,
    		VersioningConfigXML:       vcfgXML,
    		VersioningConfigUpdatedAt: now,
    		LifecycleConfigUpdatedAt:  now,
    		lifecycleConfig:           &lc,
    		versioningConfig:          &vcfg,
    	}
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri May 03 11:18:58 GMT 2024
    - 6.9K bytes
    - Viewed (0)
  2. cmd/tier-last-day-stats.go

    	UpdatedAt time.Time
    }
    
    func (l *lastDayTierStats) addStats(ts tierStats) {
    	now := time.Now()
    	l.forwardTo(now)
    
    	nowIdx := now.Hour()
    	l.Bins[nowIdx] = l.Bins[nowIdx].add(ts)
    }
    
    // forwardTo moves time to t, clearing entries between last update and t.
    func (l *lastDayTierStats) forwardTo(t time.Time) {
    	if t.IsZero() {
    		t = time.Now()
    	}
    
    	since := t.Sub(l.UpdatedAt).Hours()
    	// within the hour since l.UpdatedAt
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Feb 19 22:54:46 GMT 2024
    - 2.8K bytes
    - Viewed (0)
  3. cmd/erasure-server-pool-rebalance.go

    			select {
    			case rebalErr := <-doneCh:
    				quit = true
    				now := time.Now()
    				var status rebalStatus
    
    				switch {
    				case errors.Is(rebalErr, context.Canceled):
    					status = rebalStopped
    					traceMsg = fmt.Sprintf("stopped at %s", now)
    				case rebalErr == nil:
    					status = rebalCompleted
    					traceMsg = fmt.Sprintf("completed at %s", now)
    				default:
    					status = rebalFailed
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Apr 26 19:29:28 GMT 2024
    - 27.2K bytes
    - Viewed (0)
  4. cmd/mrf.go

    					continue
    				}
    				if wildcard.Match("multipart/*", u.object) {
    					continue
    				}
    				if wildcard.Match("tmp-old/*", u.object) {
    					continue
    				}
    			}
    
    			now := time.Now()
    			if now.Sub(u.queued) < time.Second {
    				// let recently failed networks to reconnect
    				// making MRF wait for 1s before retrying,
    				// i.e 4 reconnect attempts.
    				time.Sleep(time.Second)
    			}
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Apr 23 17:15:52 GMT 2024
    - 3.2K bytes
    - Viewed (0)
  5. cmd/erasure-common.go

    	"github.com/minio/pkg/v2/sync/errgroup"
    )
    
    func (er erasureObjects) getOnlineDisks() (newDisks []StorageAPI) {
    	disks := er.getDisks()
    	var wg sync.WaitGroup
    	var mu sync.Mutex
    	r := rand.New(rand.NewSource(time.Now().UnixNano()))
    	for _, i := range r.Perm(len(disks)) {
    		i := i
    		wg.Add(1)
    		go func() {
    			defer wg.Done()
    			if disks[i] == nil {
    				return
    			}
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 4.6K bytes
    - Viewed (0)
  6. cmd/signature-v2_test.go

    		{
    			queryParams: map[string]string{
    				"Expires":        fmt.Sprintf("%d", now.Unix()+60),
    				"Signature":      "badsignature",
    				"AWSAccessKeyId": accessKey,
    			},
    			expected: ErrSignatureDoesNotMatch,
    		},
    		// (5) Should error when the signature does not match.
    		{
    			queryParams: map[string]string{
    				"Expires":        fmt.Sprintf("%d", now.Unix()+60),
    				"Signature":      "zOM2YrY/yAQe15VWmT78OlBrK6g=",
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Oct 14 10:08:40 GMT 2022
    - 8K bytes
    - Viewed (0)
  7. internal/rest/rpc-stats.go

    	var dialStart, dialEnd int64
    
    	trace := &httptrace.ClientTrace{
    		ConnectStart: func(network, addr string) {
    			atomic.StoreInt64(&dialStart, time.Now().UnixNano())
    		},
    		ConnectDone: func(network, addr string, err error) {
    			if err == nil {
    				atomic.StoreInt64(&dialEnd, time.Now().UnixNano())
    			}
    		},
    	}
    
    	return req.WithContext(httptrace.WithClientTrace(req.Context(), trace)), func() {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Sep 29 16:27:58 GMT 2022
    - 2.3K bytes
    - Viewed (0)
  8. cmd/xl-storage-disk-id-check.go

    func newDiskHealthTracker() *diskHealthTracker {
    	d := diskHealthTracker{
    		lastSuccess: time.Now().UnixNano(),
    		lastStarted: time.Now().UnixNano(),
    	}
    	d.status.Store(diskHealthOK)
    	return &d
    }
    
    // logSuccess will update the last successful operation time.
    func (d *diskHealthTracker) logSuccess() {
    	atomic.StoreInt64(&d.lastSuccess, time.Now().UnixNano())
    }
    
    func (d *diskHealthTracker) isFaulty() bool {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 33K bytes
    - Viewed (0)
  9. cmd/os-instrumented.go

    	operations [osMetricLast]uint64
    	latency    [osMetricLast]lockedLastMinuteLatency
    }
    
    // time an os action.
    func (o *osMetrics) time(s osMetric) func() {
    	startTime := time.Now()
    	return func() {
    		duration := time.Since(startTime)
    
    		atomic.AddUint64(&o.operations[s], 1)
    		o.latency[s].add(duration)
    	}
    }
    
    // incTime will increment time on metric s with a specific duration.
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Feb 15 01:09:38 GMT 2024
    - 6.3K bytes
    - Viewed (0)
  10. internal/logger/console.go

    	if msg != "" {
    		message = fmt.Sprintf(msg, args...)
    	} else {
    		message = fmt.Sprint(args...)
    	}
    	logJSON, err := json.Marshal(&log.Entry{
    		Level:   FatalKind,
    		Message: message,
    		Time:    time.Now().UTC(),
    		Trace:   &log.Trace{Message: message, Source: []string{getSource(6)}},
    	})
    	if err != nil {
    		panic(err)
    	}
    	fmt.Fprintln(Output, string(logJSON))
    	ExitFunc(1)
    }
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Wed May 01 17:57:52 GMT 2024
    - 5.8K bytes
    - Viewed (0)
Back to top