Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 42 for ParseDuration (0.14 sec)

  1. cmd/admin-handlers-site-replication.go

    // [POST] /minio/admin/v3/site-replication/netperf
    func (a adminAPIHandlers) SiteReplicationNetPerf(w http.ResponseWriter, r *http.Request) {
    	durationStr := r.Form.Get(peerRESTDuration)
    	duration, _ := time.ParseDuration(durationStr)
    	if duration < globalNetPerfMinDuration {
    		duration = globalNetPerfMinDuration
    	}
    	result := siteNetperf(r.Context(), duration)
    	adminLogIf(r.Context(), gob.NewEncoder(w).Encode(result))
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 19.4K bytes
    - Viewed (0)
  2. cmd/bucket-replication-handlers.go

    	resetID := r.URL.Query().Get("reset-id")
    	if resetID == "" {
    		resetID = mustGetUUID()
    	}
    	var (
    		days time.Duration
    		err  error
    	)
    	if durationStr != "" {
    		days, err = time.ParseDuration(durationStr)
    		if err != nil {
    			writeErrorResponse(ctx, w, toAPIError(ctx, InvalidArgument{
    				Bucket: bucket,
    				Err:    fmt.Errorf("invalid query parameter older-than %s for %s : %w", durationStr, bucket, err),
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 23.2K bytes
    - Viewed (0)
  3. operator/pkg/helmreconciler/reconciler.go

    		opts.ProgressLog = progress.NewLog()
    	}
    	if int64(opts.WaitTimeout) == 0 {
    		if waitForResourcesTimeoutStr, found := os.LookupEnv("WAIT_FOR_RESOURCES_TIMEOUT"); found {
    			if waitForResourcesTimeout, err := time.ParseDuration(waitForResourcesTimeoutStr); err == nil {
    				opts.WaitTimeout = waitForResourcesTimeout
    			} else {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Feb 22 08:32:23 UTC 2024
    - 22K bytes
    - Viewed (0)
  4. cmd/peer-rest-server.go

    	if err != nil {
    		size = 64 * humanize.MiByte
    	}
    
    	concurrent, err := strconv.Atoi(concurrentStr)
    	if err != nil {
    		concurrent = 32
    	}
    
    	duration, err := time.ParseDuration(durationStr)
    	if err != nil {
    		duration = time.Second * 10
    	}
    
    	done := keepHTTPResponseAlive(w)
    
    	result, err := selfSpeedTest(r.Context(), speedTestOpts{
    		objectSize:      size,
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 52.1K bytes
    - Viewed (0)
  5. src/time/format.go

    	"m":  uint64(Minute),
    	"h":  uint64(Hour),
    }
    
    // ParseDuration parses a duration string.
    // A duration string is a possibly signed sequence of
    // decimal numbers, each with optional fraction and a unit suffix,
    // such as "300ms", "-1.5h" or "2h45m".
    // Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h".
    func ParseDuration(s string) (Duration, error) {
    	// [-+]?([0-9]*(\.[0-9]*)?[a-z]+)+
    	orig := s
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 11 17:09:28 UTC 2024
    - 49.3K bytes
    - Viewed (0)
  6. src/testing/benchmark.go

    		if err != nil || n < 0 || (!f.allowZero && n == 0) {
    			return fmt.Errorf("invalid count")
    		}
    		*f = durationOrCountFlag{n: int(n)}
    		return nil
    	}
    	d, err := time.ParseDuration(s)
    	if err != nil || d < 0 || (!f.allowZero && d == 0) {
    		return fmt.Errorf("invalid duration")
    	}
    	*f = durationOrCountFlag{d: d}
    	return nil
    }
    
    // Global lock to ensure only one benchmark runs at a time.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 23.9K bytes
    - Viewed (0)
  7. src/cmd/go/internal/script/cmds.go

    			},
    			Async: true,
    		},
    		func(s *State, args ...string) (WaitFunc, error) {
    			if len(args) != 1 {
    				return nil, ErrUsage
    			}
    
    			d, err := time.ParseDuration(args[0])
    			if err != nil {
    				return nil, err
    			}
    
    			timer := time.NewTimer(d)
    			wait := func(s *State) (stdout, stderr string, err error) {
    				ctx := s.Context()
    				select {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Mar 26 19:58:28 UTC 2024
    - 28.5K bytes
    - Viewed (0)
  8. pilot/pkg/networking/core/listener_inbound.go

    	}
    	tcpProxy := &tcp.TcpProxy{
    		StatPrefix:       statPrefix,
    		ClusterSpecifier: &tcp.TcpProxy_Cluster{Cluster: fcc.clusterName},
    		IdleTimeout:      parseDuration(lb.node.Metadata.IdleTimeout),
    	}
    	tcpFilter := setAccessLogAndBuildTCPFilter(lb.push, lb.node, tcpProxy, istionetworking.ListenerClassSidecarInbound, fcc.policyService)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Jun 13 01:56:28 UTC 2024
    - 35.1K bytes
    - Viewed (0)
  9. src/database/sql/fakedb_test.go

    		if firstStmt == nil {
    			firstStmt = stmt
    		}
    		if len(parts) >= 3 {
    			switch parts[0] {
    			case "PANIC":
    				stmt.panic = parts[1]
    				parts = parts[2:]
    			case "WAIT":
    				wait, err := time.ParseDuration(parts[1])
    				if err != nil {
    					return nil, errf("expected section after WAIT to be a duration, got %q %v", parts[1], err)
    				}
    				parts = parts[2:]
    				stmt.wait = wait
    			}
    		}
    		cmd := parts[0]
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 01 12:38:07 UTC 2024
    - 30.3K bytes
    - Viewed (0)
  10. pilot/pkg/config/kube/gateway/conversion.go

    			}
    		}
    	}
    
    	if r.Timeouts != nil {
    		if r.Timeouts.Request != nil {
    			request, _ := time.ParseDuration(string(*r.Timeouts.Request))
    			if request != 0 {
    				vs.Timeout = durationpb.New(request)
    			}
    		}
    		if r.Timeouts.BackendRequest != nil {
    			backendRequest, _ := time.ParseDuration(string(*r.Timeouts.BackendRequest))
    			if backendRequest != 0 {
    				timeout := durationpb.New(backendRequest)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Fri Jun 14 04:34:37 UTC 2024
    - 84.7K bytes
    - Viewed (0)
Back to top