Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 279 for _new (0.16 sec)

  1. tests/migrate_test.go

    		"new_new_name"); err != nil {
    		t.Fatalf("Failed to add column, got %v", err)
    	}
    
    	if !DB.Table("column_structs").Migrator().HasColumn(&NewColumnStruct{}, "new_new_name") {
    		t.Fatalf("Failed to found renamed column")
    	}
    
    	if err := DB.Table("column_structs").Migrator().DropColumn(&NewColumnStruct{}, "new_new_name"); err != nil {
    		t.Fatalf("Failed to add column, got %v", err)
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Mar 18 11:24:16 GMT 2024
    - 56.2K bytes
    - Viewed (0)
  2. internal/crypto/key.go

    	}
    	if len(extKey) != 32 { // safety check
    		logger.CriticalIf(context.Background(), errors.New("crypto: invalid key length"))
    	}
    	var nonce [32]byte
    	if _, err := io.ReadFull(random, nonce[:]); err != nil {
    		logger.CriticalIf(context.Background(), errOutOfEntropy)
    	}
    
    	const Context = "object-encryption-key generation"
    	mac := hmac.New(sha256.New, extKey)
    	mac.Write([]byte(Context))
    	mac.Write(nonce[:])
    	mac.Sum(key[:0])
    	return key
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Mar 19 20:28:10 GMT 2024
    - 6.4K bytes
    - Viewed (0)
  3. internal/cachevalue/cache.go

    	valErr atomic.Pointer[struct {
    		v T
    		e error
    	}]
    	lastUpdateMs atomic.Int64
    	updating     sync.Mutex
    }
    
    // New allocates a new cached value instance. Tt must be initialized with
    // `.TnitOnce`.
    func New[T any]() *Cache[T] {
    	return &Cache[T]{}
    }
    
    // NewFromFunc allocates a new cached value instance and initializes it with an
    // update function, making it ready for use.
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Mar 01 16:00:42 GMT 2024
    - 4.2K bytes
    - Viewed (0)
  4. cmd/peer-rest-server.go

    	getPeerMetricsRPC              = grid.NewSingleHandler[*grid.MSS, *grid.Array[*MetricV2]](grid.HandlerGetPeerMetrics, grid.NewMSS, aoMetricsGroup.New)
    	getResourceMetricsRPC          = grid.NewSingleHandler[*grid.MSS, *grid.Array[*MetricV2]](grid.HandlerGetResourceMetrics, grid.NewMSS, aoMetricsGroup.New)
    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)
  5. internal/bpool/bpool.go

    // BytePoolCap implements a leaky pool of []byte in the form of a bounded channel.
    type BytePoolCap struct {
    	c    chan []byte
    	w    int
    	wcap int
    }
    
    // NewBytePoolCap creates a new BytePool bounded to the given maxSize, with new
    // byte arrays sized based on width.
    func NewBytePoolCap(maxSize uint64, width int, capwidth int) (bp *BytePoolCap) {
    	if capwidth > 0 && capwidth < 64 {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Apr 19 16:44:59 GMT 2024
    - 2.6K bytes
    - Viewed (0)
  6. cmd/warm-backend-azure.go

    		credential azblob.Credential
    		err        error
    	)
    
    	switch {
    	case conf.AccountName == "":
    		return nil, errors.New("the account name is required")
    	case conf.AccountKey != "" && (conf.SPAuth.TenantID != "" || conf.SPAuth.ClientID != "" || conf.SPAuth.ClientSecret != ""):
    		return nil, errors.New("multiple authentication mechanisms are provided")
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Mar 05 16:44:08 GMT 2024
    - 7.8K bytes
    - Viewed (1)
  7. cmd/warm-backend-minio.go

    	// Validation of credentials
    	if conf.AccessKey == "" || conf.SecretKey == "" {
    		return nil, errors.New("both access and secret keys are required")
    	}
    
    	if conf.Bucket == "" {
    		return nil, errors.New("no bucket name was provided")
    	}
    
    	u, err := url.Parse(conf.Endpoint)
    	if err != nil {
    		return nil, err
    	}
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 21 11:43:18 GMT 2024
    - 3.8K bytes
    - Viewed (0)
  8. internal/grid/handlers.go

    // Any error seen on a remote will be returned like this.
    type RemoteErr string
    
    // NewRemoteErr creates a new remote error.
    // The error type is not preserved.
    func NewRemoteErr(err error) *RemoteErr {
    	if err == nil {
    		return nil
    	}
    	r := RemoteErr(err.Error())
    	return &r
    }
    
    // NewRemoteErrf creates a new remote error from a format string.
    func NewRemoteErrf(format string, a ...any) *RemoteErr {
    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)
  9. cmd/consolelogger.go

    	nodeName string
    	logBuf   *ring.Ring
    }
    
    // NewConsoleLogger - creates new HTTPConsoleLoggerSys with all nodes subscribed to
    // the console logging pub sub system
    func NewConsoleLogger(ctx context.Context, w io.Writer) *HTTPConsoleLoggerSys {
    	return &HTTPConsoleLoggerSys{
    		pubsub:  pubsub.New[log.Info, madmin.LogMask](8),
    		console: console.New(w),
    		logBuf:  ring.New(defaultLogBufferCount),
    	}
    }
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Wed May 01 17:57:52 GMT 2024
    - 5.5K bytes
    - Viewed (0)
  10. migrator/migrator.go

    						if !beDependedOn[rel.FieldSchema] {
    							dep.Depends = append(dep.Depends, rel.FieldSchema)
    						} else {
    							fieldValue := reflect.New(rel.FieldSchema.ModelType).Interface()
    							parseDependence(fieldValue, autoAdd)
    						}
    						parseDependence(joinValue, autoAdd)
    					}(rel, reflect.New(rel.JoinTable.ModelType).Interface())
    				}
    			}
    		}
    
    		valuesMap[dep.Schema.Table] = dep
    
    		if addToList {
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Fri Apr 26 07:15:49 GMT 2024
    - 29K bytes
    - Viewed (0)
Back to top