Search Options

Results per page
Sort
Preferred Languages
Advance

Results 311 - 320 of 1,025 for _func (0.02 sec)

  1. cmd/warm-backend-gcs.go

    	client       *storage.Client
    	Bucket       string
    	Prefix       string
    	StorageClass string
    }
    
    func (gcs *warmBackendGCS) getDest(object string) string {
    	destObj := object
    	if gcs.Prefix != "" {
    		destObj = fmt.Sprintf("%s/%s", gcs.Prefix, object)
    	}
    	return destObj
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Oct 31 22:10:24 UTC 2024
    - 6.1K bytes
    - Viewed (0)
  2. schema/naming_test.go

    	}
    }
    
    type CustomReplacer struct {
    	f func(string) string
    }
    
    func (r CustomReplacer) Replace(name string) string {
    	return r.f(name)
    }
    
    func TestCustomReplacer(t *testing.T) {
    	ns := NamingStrategy{
    		TablePrefix:   "public.",
    		SingularTable: true,
    		NameReplacer: CustomReplacer{
    			func(name string) string {
    				replaced := "REPLACED_" + strings.ToUpper(name)
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Tue May 30 02:00:48 UTC 2023
    - 7K bytes
    - Viewed (0)
  3. cmd/erasure-metadata-utils_test.go

    	if err != nil {
    		removeRoots(disks)
    		t.Fatal(err)
    	}
    	defer removeRoots(disks)
    	z := objLayer.(*erasureServerPools)
    	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[:])
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Jan 18 07:03:17 UTC 2024
    - 7.4K bytes
    - Viewed (0)
  4. cmd/api-headers.go

    	xxml "github.com/minio/xxml"
    )
    
    // Returns a hexadecimal representation of time at the
    // time response is sent to the client.
    func mustGetRequestID(t time.Time) string {
    	return fmt.Sprintf("%X", t.UnixNano())
    }
    
    // setEventStreamHeaders to allow proxies to avoid buffering proxy responses
    func setEventStreamHeaders(w http.ResponseWriter) {
    	w.Header().Set(xhttp.ContentType, "text/event-stream")
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue May 28 04:44:00 UTC 2024
    - 7K bytes
    - Viewed (0)
  5. cmd/kms-handlers_test.go

    	adminTestBed, err := prepareAdminErasureTestBed(context.Background())
    	if err != nil {
    		t.Fatal(err)
    	}
    	registerKMSRouter(adminTestBed.router)
    
    	if enableKMS {
    		GlobalKMS = kms.NewStub("default-test-key")
    	}
    
    	tearDown := func() {
    		adminTestBed.TearDown()
    		GlobalKMS = nil
    	}
    	return adminTestBed, tearDown
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Aug 18 06:43:03 UTC 2024
    - 22.3K bytes
    - Viewed (0)
  6. cmd/handler-utils.go

    	}
    	return path, nil
    }
    
    var regexVersion = regexp.MustCompile(`^/minio.*/(v\d+)/.*`)
    
    func extractAPIVersion(r *http.Request) string {
    	if matches := regexVersion.FindStringSubmatch(r.URL.Path); len(matches) > 1 {
    		return matches[1]
    	}
    	return "unknown"
    }
    
    func methodNotAllowedHandler(api string) func(w http.ResponseWriter, r *http.Request) {
    	return errorResponseHandler
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Jun 10 15:31:51 UTC 2024
    - 15.5K bytes
    - Viewed (0)
  7. cmd/tier.go

    	}, []string{"tier"}),
    }
    
    func (t *tierMetrics) Observe(tier string, dur time.Duration) {
    	t.histogram.With(prometheus.Labels{"tier": tier}).Observe(dur.Seconds())
    }
    
    func (t *tierMetrics) logSuccess(tier string) {
    	t.Lock()
    	defer t.Unlock()
    
    	stat := t.requestsCount[tier]
    	stat.success++
    	t.requestsCount[tier] = stat
    }
    
    func (t *tierMetrics) logFailure(tier string) {
    	t.Lock()
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Sep 12 20:44:05 UTC 2024
    - 15.7K bytes
    - Viewed (0)
  8. internal/bucket/replication/rule.go

    	Status Status `xml:"Status"` // should be set to "Disabled" by default
    }
    
    // IsEmpty returns true if DeleteMarkerReplication is not set
    func (d DeleteMarkerReplication) IsEmpty() bool {
    	return len(d.Status) == 0
    }
    
    // Validate validates whether the status is disabled.
    func (d DeleteMarkerReplication) Validate() error {
    	if d.IsEmpty() {
    		return errDeleteMarkerReplicationMissing
    	}
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Jan 24 23:22:20 UTC 2022
    - 8.3K bytes
    - Viewed (0)
  9. cmd/erasure-server-pool.go

    	}
    
    	var unlockOnDefer bool
    	nsUnlocker := func() {}
    	defer func() {
    		if unlockOnDefer {
    			nsUnlocker()
    		}
    	}()
    
    	// Acquire lock
    	if !opts.NoLock {
    		lock := z.NewNSLock(bucket, object)
    		lkctx, err := lock.GetRLock(ctx, globalOperationTimeout)
    		if err != nil {
    			return nil, err
    		}
    		ctx = lkctx.Context()
    		nsUnlocker = func() { lock.RUnlock(lkctx) }
    		unlockOnDefer = true
    	}
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Sep 29 22:40:36 UTC 2024
    - 89.8K bytes
    - Viewed (0)
  10. cmd/erasure-server-pool-rebalance_gen.go

    	"github.com/tinylib/msgp/msgp"
    )
    
    // DecodeMsg implements msgp.Decodable
    func (z *rebalSaveOpts) DecodeMsg(dc *msgp.Reader) (err error) {
    	{
    		var zb0001 uint8
    		zb0001, err = dc.ReadUint8()
    		if err != nil {
    			err = msgp.WrapError(err)
    			return
    		}
    		(*z) = rebalSaveOpts(zb0001)
    	}
    	return
    }
    
    // EncodeMsg implements msgp.Encodable
    func (z rebalSaveOpts) EncodeMsg(en *msgp.Writer) (err error) {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Mar 21 17:21:35 UTC 2024
    - 26.8K bytes
    - Viewed (0)
Back to top