Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 2,232 for func (0.16 sec)

  1. cmd/config-dir.go

    type ConfigDir struct {
    	path string
    }
    
    func getDefaultConfigDir() string {
    	homeDir, err := homedir.Dir()
    	if err != nil {
    		return ""
    	}
    
    	return filepath.Join(homeDir, defaultMinioConfigDir)
    }
    
    func getDefaultCertsDir() string {
    	return filepath.Join(getDefaultConfigDir(), certsDir)
    }
    
    func getDefaultCertsCADir() string {
    	return filepath.Join(getDefaultCertsDir(), certsCADir)
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Jan 02 17:15:06 GMT 2022
    - 3K bytes
    - Viewed (0)
  2. internal/store/queuestore_test.go

    	testItemExt = ".test"
    )
    
    // Initialize the queue store.
    func setUpQueueStore(directory string, limit uint64) (Store[TestItem], error) {
    	queueStore := NewQueueStore[TestItem](queueDir, limit, testItemExt)
    	if oErr := queueStore.Open(); oErr != nil {
    		return nil, oErr
    	}
    	return queueStore, nil
    }
    
    // Tear down queue store.
    func tearDownQueueStore() error {
    	return os.RemoveAll(queueDir)
    }
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Apr 04 17:52:24 GMT 2023
    - 5.9K bytes
    - Viewed (0)
  3. cmd/xl-storage-format-v2_test.go

    		},
    	}
    	for _, test := range testCases {
    		t.Run(test.name, func(t *testing.T) {
    			// Run multiple times, shuffling the input order.
    			for i := int64(0); i < 50; i++ {
    				t.Run(fmt.Sprint(i), func(t *testing.T) {
    					rng := rand.New(rand.NewSource(i))
    					rng.Shuffle(len(test.input), func(i, j int) {
    						test.input[i], test.input[j] = test.input[j], test.input[i]
    					})
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Mar 08 17:50:48 GMT 2024
    - 36.4K bytes
    - Viewed (0)
  4. internal/grid/msg_gen_test.go

    		t.Fatal(err)
    	}
    	if len(left) > 0 {
    		t.Errorf("%d bytes left over after Skip(): %q", len(left), left)
    	}
    }
    
    func BenchmarkMarshalMsgconnectReq(b *testing.B) {
    	v := connectReq{}
    	b.ReportAllocs()
    	b.ResetTimer()
    	for i := 0; i < b.N; i++ {
    		v.MarshalMsg(nil)
    	}
    }
    
    func BenchmarkAppendMsgconnectReq(b *testing.B) {
    	v := connectReq{}
    	bts := make([]byte, 0, v.Msgsize())
    	bts, _ = v.MarshalMsg(bts[0:0])
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Nov 21 01:09:35 GMT 2023
    - 10.8K bytes
    - Viewed (0)
  5. cmd/erasure-server-pool-decom_gen_test.go

    		t.Fatal(err)
    	}
    	if len(left) > 0 {
    		t.Errorf("%d bytes left over after Skip(): %q", len(left), left)
    	}
    }
    
    func BenchmarkMarshalMsgPoolDecommissionInfo(b *testing.B) {
    	v := PoolDecommissionInfo{}
    	b.ReportAllocs()
    	b.ResetTimer()
    	for i := 0; i < b.N; i++ {
    		v.MarshalMsg(nil)
    	}
    }
    
    func BenchmarkAppendMsgPoolDecommissionInfo(b *testing.B) {
    	v := PoolDecommissionInfo{}
    	bts := make([]byte, 0, v.Msgsize())
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Wed Jan 12 02:48:43 GMT 2022
    - 11K bytes
    - Viewed (0)
  6. cmd/xl-storage-format-v2_gen_test.go

    		t.Fatal(err)
    	}
    	if len(left) > 0 {
    		t.Errorf("%d bytes left over after Skip(): %q", len(left), left)
    	}
    }
    
    func BenchmarkMarshalMsgxlMetaDataDirDecoder(b *testing.B) {
    	v := xlMetaDataDirDecoder{}
    	b.ReportAllocs()
    	b.ResetTimer()
    	for i := 0; i < b.N; i++ {
    		v.MarshalMsg(nil)
    	}
    }
    
    func BenchmarkAppendMsgxlMetaDataDirDecoder(b *testing.B) {
    	v := xlMetaDataDirDecoder{}
    	bts := make([]byte, 0, v.Msgsize())
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Nov 18 20:15:22 GMT 2021
    - 11.5K bytes
    - Viewed (0)
  7. istioctl/pkg/admin/istiodconfig.go

    	client       *ControlzClient
    	outputFormat string
    }
    
    func (ga *getAllLogLevelsState) run(out io.Writer) error {
    	type scopeLogLevel struct {
    		ScopeName   string `json:"scope_name"`
    		LogLevel    string `json:"log_level"`
    		Description string `json:"description"`
    	}
    	allScopes, err := ga.client.GetScopes()
    	sort.Slice(allScopes, func(i, j int) bool {
    		return allScopes[i].Name < allScopes[j].Name
    	})
    Go
    - Registered: Wed May 01 22:53:12 GMT 2024
    - Last Modified: Sat Apr 13 05:23:38 GMT 2024
    - 13.5K bytes
    - Viewed (0)
  8. cmd/data-scanner-metric.go

    func (p *scannerMetrics) currentPathUpdater(disk, initial string) (update func(path string), done func()) {
    	initialPtr := unsafe.Pointer(&initial)
    	tracker := &currentPathTracker{
    		name: &initialPtr,
    	}
    
    	p.currentPaths.Store(disk, tracker)
    	return func(path string) {
    			atomic.StorePointer(tracker.name, unsafe.Pointer(&path))
    		}, func() {
    			p.currentPaths.Delete(disk)
    		}
    }
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Sep 25 05:15:31 GMT 2023
    - 9.1K bytes
    - Viewed (0)
  9. internal/dsync/drwmutex_test.go

    	hammerRWMutex(t, 10, 5, n)
    }
    
    // Borrowed from rwmutex_test.go
    func TestUnlockPanic(t *testing.T) {
    	defer func() {
    		if recover() == nil {
    			t.Fatalf("unlock of unlocked RWMutex did not panic")
    		}
    	}()
    	mu := NewDRWMutex(ds, "test")
    	mu.Unlock(context.Background())
    }
    
    // Borrowed from rwmutex_test.go
    func TestUnlockPanic2(t *testing.T) {
    	mu := NewDRWMutex(ds, "test-unlock-panic-2")
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sat Dec 24 03:49:07 GMT 2022
    - 9.7K bytes
    - Viewed (0)
  10. cmd/batch-handlers.go

    func (oi ObjectInfo) TraceVersionID() string {
    	return oi.VersionID
    }
    
    func (m *batchJobMetrics) trace(d batchJobMetric, job string, attempts int) func(info objTraceInfoer, err error) {
    	startTime := time.Now()
    	return func(info objTraceInfoer, err error) {
    		duration := time.Since(startTime)
    		if globalTrace.NumSubscribers(madmin.TraceBatch) > 0 {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Apr 08 14:11:38 GMT 2024
    - 55.2K bytes
    - Viewed (0)
Back to top