Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 355 for once (0.14 sec)

  1. cmd/prepare-storage.go

    		}
    		// Once is set and we are here means error was already
    		// printed once.
    		if once {
    			return
    		}
    		// once not set, check if same error occurred 3 times in
    		// a row, then make sure we print it to call attention.
    		if m[err.Error()] > 2 {
    			peersLogAlwaysIf(ctx, fmt.Errorf("Following error has been printed %d times.. %w", m[err.Error()], err))
    			// Reduce the count to introduce further delay in printing
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Apr 15 08:25:46 GMT 2024
    - 11.1K bytes
    - Viewed (0)
  2. internal/cachevalue/cache.go

    	// If an error is returned the cached value is not set.
    	// Only one caller will call this function at any time, others will be blocking.
    	// The returned value can no longer be modified once returned.
    	// Should be set before calling Get().
    	updateFn func() (T, error)
    
    	// ttl for a cached value.
    	ttl time.Duration
    
    	opts Opts
    
    	// Once can be used to initialize values for lazy initialization.
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Mar 01 16:00:42 GMT 2024
    - 4.2K bytes
    - Viewed (0)
  3. internal/ioutil/wait_pipe.go

    	"sync"
    )
    
    // PipeWriter is similar to io.PipeWriter with wait group
    type PipeWriter struct {
    	*io.PipeWriter
    	once sync.Once
    	done func()
    }
    
    // CloseWithError close with supplied error the writer end.
    func (w *PipeWriter) CloseWithError(err error) error {
    	err = w.PipeWriter.CloseWithError(err)
    	w.once.Do(func() {
    		w.done()
    	})
    	return err
    }
    
    // PipeReader is similar to io.PipeReader with wait group
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 27 14:55:36 GMT 2023
    - 1.7K bytes
    - Viewed (0)
  4. internal/event/target/redis.go

    	"net/url"
    	"os"
    	"path/filepath"
    	"strings"
    	"time"
    
    	"github.com/gomodule/redigo/redis"
    	"github.com/minio/minio/internal/event"
    	"github.com/minio/minio/internal/logger"
    	"github.com/minio/minio/internal/once"
    	"github.com/minio/minio/internal/store"
    	xnet "github.com/minio/pkg/v2/net"
    )
    
    // Redis constants
    const (
    	RedisFormat     = "format"
    	RedisAddress    = "address"
    	RedisPassword   = "password"
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Tue Mar 19 04:37:54 GMT 2024
    - 9.1K bytes
    - Viewed (0)
  5. cmd/service.go

    // freezeServices will freeze all incoming S3 API calls.
    // For each call, unfreezeServices must be called once.
    func freezeServices() {
    	// Use atomics for globalServiceFreeze, so we can read without locking.
    	// We need a lock since we are need the 2 atomic values to remain in sync.
    	globalServiceFreezeMu.Lock()
    	// If multiple calls, first one creates channel.
    	globalServiceFreezeCnt++
    	if globalServiceFreezeCnt == 1 {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Wed Feb 28 07:02:14 GMT 2024
    - 3.8K bytes
    - Viewed (0)
  6. internal/etag/reader.go

    // A Reader wraps an io.Reader and computes the
    // MD5 checksum of the read content as ETag.
    //
    // Optionally, a Reader can also verify that
    // the computed ETag matches an expected value.
    // Therefore, it compares both ETags once the
    // underlying io.Reader returns io.EOF.
    // If the computed ETag does not match the
    // expected ETag then Read returns a VerifyError.
    //
    // Reader implements the Tagger interface.
    type Reader struct {
    	src io.Reader
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Jan 18 07:03:17 GMT 2024
    - 4.8K bytes
    - Viewed (0)
  7. src/arena/arena.go

    // Arenas are useful for improving efficiency as they may be freed back to
    // the runtime manually, though any memory obtained from freed arenas must
    // not be accessed once that happens. An Arena is automatically freed once
    // it is no longer referenced, so it must be kept alive (see runtime.KeepAlive)
    // until any memory allocated from it is no longer needed.
    //
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Wed Oct 12 20:23:36 GMT 2022
    - 4.3K bytes
    - Viewed (0)
  8. cmd/erasure-coding.go

    	}
    
    	e = Erasure{
    		dataBlocks:   dataBlocks,
    		parityBlocks: parityBlocks,
    		blockSize:    blockSize,
    	}
    
    	// Encoder when needed.
    	var enc reedsolomon.Encoder
    	var once sync.Once
    	e.encoder = func() reedsolomon.Encoder {
    		once.Do(func() {
    			e, err := reedsolomon.New(dataBlocks, parityBlocks, reedsolomon.WithAutoGoroutines(int(e.ShardSize())))
    			if err != nil {
    				// Error conditions should be checked above.
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Wed Jan 31 02:11:45 GMT 2024
    - 8.6K bytes
    - Viewed (0)
  9. internal/bucket/lifecycle/lifecycle.go

    var (
    	errLifecycleTooManyRules = Errorf("Lifecycle configuration allows a maximum of 1000 rules")
    	errLifecycleNoRule       = Errorf("Lifecycle configuration should have at least one rule")
    	errLifecycleDuplicateID  = Errorf("Rule ID must be unique. Found same ID for more than one rule")
    	errXMLNotWellFormed      = Errorf("The XML you provided was not well-formed or did not validate against our published schema")
    )
    
    const (
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sat Mar 09 06:41:22 GMT 2024
    - 17K bytes
    - Viewed (0)
  10. internal/config/lambda/target/lazyinit.go

    // along with this program.  If not, see <http://www.gnu.org/licenses/>.
    
    package target
    
    import (
    	"sync"
    	"sync/atomic"
    )
    
    // Inspired from Golang sync.Once but it is only marked
    // initialized when the provided function returns nil.
    
    type lazyInit struct {
    	done uint32
    	m    sync.Mutex
    }
    
    func (l *lazyInit) Do(f func() error) error {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Tue Mar 07 16:12:41 GMT 2023
    - 1.3K bytes
    - Viewed (0)
Back to top