Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 24 for Recycle (0.19 sec)

  1. internal/grid/types.go

    	"sort"
    	"strings"
    	"sync"
    
    	"github.com/tinylib/msgp/msgp"
    )
    
    // Recycler will override the internal reuse in typed handlers.
    // When this is supported, the handler will not do internal pooling of objects,
    // call Recycle() when the object is no longer needed.
    // The recycler should handle nil pointers.
    type Recycler interface {
    	Recycle()
    }
    
    // MSS is a map[string]string that can be serialized.
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Apr 01 23:42:09 GMT 2024
    - 15.4K bytes
    - Viewed (0)
  2. internal/grid/handlers.go

    	recycleResp func(Resp)
    }
    
    func recycleFunc[RT RoundTripper](newRT func() RT) (newFn func() RT, recycle func(r RT)) {
    	rAny := any(newRT())
    	var rZero RT
    	if _, ok := rAny.(Recycler); ok {
    		return newRT, func(r RT) {
    			if r != rZero {
    				if rc, ok := any(r).(Recycler); ok {
    					rc.Recycle()
    				}
    			}
    		}
    	}
    	pool := sync.Pool{
    		New: func() interface{} {
    			return newRT()
    		},
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Apr 23 17:15:52 GMT 2024
    - 27.1K bytes
    - Viewed (0)
  3. cmd/peer-s3-client.go

    	}
    	buckets := make([]BucketInfo, 0, len(bi.Value()))
    	for _, b := range bi.Value() {
    		if b != nil {
    			buckets = append(buckets, *b)
    		}
    	}
    	bi.Recycle() // BucketInfo has no internal pointers, so it's safe to recycle.
    	return buckets, nil
    }
    
    func (client *remotePeerS3Client) HealBucket(ctx context.Context, bucket string, opts madmin.HealOpts) (madmin.HealResultItem, error) {
    	conn := client.gridConn()
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 14.8K bytes
    - Viewed (0)
  4. cmd/storage-datatypes.go

    	buf := grid.GetByteBufferCap(32 + 16<<10)
    	return &RenameDataInlineHandlerParams{RenameDataHandlerParams{FI: FileInfo{Data: buf[:0]}}}
    }
    
    // Recycle will reuse the memory allocated for the FileInfo data.
    func (r *RenameDataInlineHandlerParams) Recycle() {
    	if r == nil {
    		return
    	}
    	if cap(r.FI.Data) >= xioutil.SmallBlock {
    		grid.PutByteBuffer(r.FI.Data)
    		r.FI.Data = nil
    	}
    }
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Apr 23 17:15:52 GMT 2024
    - 15.3K bytes
    - Viewed (0)
  5. cmd/peer-rest-client.go

    	if err != nil {
    		return
    	}
    	st.Results(func(b []byte) error {
    		select {
    		case traceCh <- b:
    		default:
    			// Do not block on slow receivers.
    			// Just recycle the buffer.
    			grid.PutByteBuffer(b)
    		}
    		return nil
    	})
    }
    
    func (client *peerRESTClient) doListen(ctx context.Context, listenCh chan<- []byte, v url.Values) {
    	conn := client.gridConn()
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 25.8K bytes
    - Viewed (0)
  6. internal/grid/grid_test.go

    			(*resp)[k] = v
    		}
    		return resp, nil
    	}
    	// Return error
    	h2 := NewSingleHandler[*MSS, *MSS](handlerTest2, NewMSS, NewMSS)
    	handler2 := func(req *MSS) (resp *MSS, err *RemoteErr) {
    		defer req.Recycle()
    		r := RemoteErr(req.Get("err"))
    		return nil, &r
    	}
    	errFatal(h1.Register(local, handler1))
    	errFatal(h2.Register(local, handler2))
    
    	errFatal(h1.Register(remote, handler1))
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Apr 30 15:03:35 GMT 2024
    - 30.1K bytes
    - Viewed (0)
  7. cmd/license-update.go

    	for {
    		select {
    		case <-ctx.Done():
    			return
    		case <-licenseUpdateTimer.C:
    
    			if globalSubnetConfig.Registered() {
    				performLicenseUpdate(ctx, objAPI)
    			}
    
    			// Reset the timer for next cycle.
    			licenseUpdateTimer.Reset(licUpdateCycle)
    		}
    	}
    }
    
    func performLicenseUpdate(ctx context.Context, objectAPI ObjectLayer) {
    	// the subnet license renewal api renews the license only
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 3.3K bytes
    - Viewed (0)
  8. docs/config/README.md

    ARGS:
    delay     (float)     scanner delay multiplier, defaults to '10.0'
    max_wait  (duration)  maximum wait time between operations, defaults to '15s'
    cycle     (duration)  time duration between scanner cycles
    ```
    
    Example: the following setting will decrease the scanner speed by a factor of 3, reducing the system resource use, but increasing the latency of updates being reflected.
    Plain Text
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Sep 11 21:48:54 GMT 2023
    - 17.7K bytes
    - Viewed (0)
  9. cmd/testdata/undeleteable-object.tgz

    :""}]},"scanner":{"_":[{"key":"speed","value":"default"},{"key":"idle_speed","value":""},{"key":"alert_excess_versions","value":"100"},{"key":"alert_excess_folders","value":"50000"},{"key":"delay","value":""},{"key":"max_wait","value":""},{"key":"cycle","value":""}]},"site":{"_":[{"key":"name","value":""},{"key":"region","value":""}]},"storage_class":{"_":[{"key":"standard","value":"EC:5"},{"key":"rrs","value":"EC:1"},{"key":"optimize","value":"availability"},{"key":"inline_block","value":""}]},...
    Others
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Apr 26 00:31:12 GMT 2024
    - 8.7M bytes
    - Viewed (0)
  10. cmd/peer-rest-server.go

    // ListenHandler sends http trace messages back to peer rest client
    func (s *peerRESTServer) ListenHandler(ctx context.Context, v *grid.URLValues, out chan<- *grid.Bytes) *grid.RemoteErr {
    	values := v.Values()
    	defer v.Recycle()
    	var prefix string
    	if len(values[peerRESTListenPrefix]) > 1 {
    		return grid.NewRemoteErrString("invalid request (peerRESTListenPrefix)")
    	}
    	globalAPIConfig.getRequestsPoolCapacity()
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 51.8K bytes
    - Viewed (0)
Back to top