Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 29 for IsValid (0.22 sec)

  1. internal/bucket/replication/sourceselectioncriteria.go

    type SourceSelectionCriteria struct {
    	ReplicaModifications ReplicaModifications `xml:"ReplicaModifications" json:"ReplicaModifications"`
    }
    
    // IsValid - checks whether SourceSelectionCriteria is valid or not.
    func (s SourceSelectionCriteria) IsValid() bool {
    	return s.ReplicaModifications.Status == Enabled || s.ReplicaModifications.Status == Disabled
    }
    
    // Validate source selection criteria
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Jun 01 21:59:40 GMT 2021
    - 2.5K bytes
    - Viewed (0)
  2. internal/bucket/replication/destination.go

    func (d Destination) isValidStorageClass() bool {
    	if d.StorageClass == "" {
    		return true
    	}
    	return d.StorageClass == "STANDARD" || d.StorageClass == "REDUCED_REDUNDANCY"
    }
    
    // IsValid - checks whether Destination is valid or not.
    func (d Destination) IsValid() bool {
    	return d.Bucket != "" || !d.isValidStorageClass()
    }
    
    func (d Destination) String() string {
    	return d.ARN
    }
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Sep 04 19:57:37 GMT 2023
    - 4K bytes
    - Viewed (2)
  3. cmd/peer-rest-server.go

    }
    
    // HealthHandler - returns true of health
    func (s *peerRESTServer) HealthHandler(w http.ResponseWriter, r *http.Request) {
    	s.IsValid(w, r)
    }
    
    // VerifyBinary - verifies the downloaded binary is in-tact
    func (s *peerRESTServer) VerifyBinaryHandler(w http.ResponseWriter, r *http.Request) {
    	if !s.IsValid(w, r) {
    		s.writeErrorResponse(w, errors.New("Invalid request"))
    		return
    	}
    
    	if r.ContentLength < 0 {
    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)
  4. cmd/erasure-metadata.go

    }
    
    // ShardSize - returns actual shared size from erasure blockSize.
    func (e ErasureInfo) ShardSize() int64 {
    	return ceilFrac(e.BlockSize, int64(e.DataBlocks))
    }
    
    // IsValid - tells if erasure info fields are valid.
    func (fi FileInfo) IsValid() bool {
    	if fi.Deleted {
    		// Delete marker has no data, no need to check
    		// for erasure coding information
    		return true
    	}
    	dataBlocks := fi.Erasure.DataBlocks
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 19.2K bytes
    - Viewed (1)
  5. cmd/storage-rest-server.go

    	if err := storageServerRequestValidate(r); err != nil {
    		s.writeErrorResponse(w, err)
    		return false
    	}
    
    	return true
    }
    
    // IsValid - To authenticate and check if the disk-id in the request corresponds to the underlying disk.
    func (s *storageRESTServer) IsValid(w http.ResponseWriter, r *http.Request) bool {
    	if !s.IsAuthValid(w, r) {
    		return false
    	}
    
    	if err := r.ParseForm(); err != nil {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 44.8K bytes
    - Viewed (0)
  6. cmd/erasure-object.go

    	freeVersionID := fi.TierFreeVersionID()
    	freeVersionMarker := fi.TierFreeVersion()
    
    	// Update `xl.meta` content on each disks.
    	for index := range metaArr {
    		if metaArr[index].IsValid() {
    			metaArr[index].ModTime = modTime
    			metaArr[index].VersionID = versionID
    			if !metaArr[index].InlineData() {
    				// If the data is not inlined, we may end up incorrectly
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun May 05 16:56:21 GMT 2024
    - 77.2K bytes
    - Viewed (2)
  7. cmd/bucket-targets.go

    }
    
    // SetTarget - sets a new minio-go client target for this bucket.
    func (sys *BucketTargetSys) SetTarget(ctx context.Context, bucket string, tgt *madmin.BucketTarget, update bool) error {
    	if !tgt.Type.IsValid() && !update {
    		return BucketRemoteArnTypeInvalid{Bucket: bucket}
    	}
    	clnt, err := sys.getRemoteTargetClient(tgt)
    	if err != nil {
    		return BucketRemoteTargetNotFound{Bucket: tgt.TargetBucket, Err: err}
    	}
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Wed May 01 01:09:56 GMT 2024
    - 20.9K bytes
    - Viewed (0)
  8. internal/auth/credentials_test.go

    		}
    	}
    }
    
    func TestGetNewCredentials(t *testing.T) {
    	cred, err := GetNewCredentials()
    	if err != nil {
    		t.Fatalf("Failed to get a new credential")
    	}
    	if !cred.IsValid() {
    		t.Fatalf("Failed to get new valid credential")
    	}
    	if len(cred.AccessKey) != accessKeyMaxLen {
    		t.Fatalf("access key length: expected: %v, got: %v", secretKeyMaxLen, len(cred.AccessKey))
    	}
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Mar 01 21:09:42 GMT 2024
    - 5.4K bytes
    - Viewed (0)
  9. internal/config/storageclass/storage-class.go

    	type Alias Config
    	aux := &struct {
    		*Alias
    	}{
    		Alias: (*Alias)(sCfg),
    	}
    	return json.Unmarshal(data, &aux)
    }
    
    // IsValid - returns true if input string is a valid
    // storage class kind supported.
    func IsValid(sc string) bool {
    	return sc == RRS || sc == STANDARD
    }
    
    // UnmarshalText unmarshals storage class from its textual form into
    // storageClass structure.
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 11.8K bytes
    - Viewed (0)
  10. cmd/bucket-quota.go

    func parseBucketQuota(bucket string, data []byte) (quotaCfg *madmin.BucketQuota, err error) {
    	quotaCfg = &madmin.BucketQuota{}
    	if err = json.Unmarshal(data, quotaCfg); err != nil {
    		return quotaCfg, err
    	}
    	if !quotaCfg.IsValid() {
    		if quotaCfg.Type == "fifo" {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 4.3K bytes
    - Viewed (0)
Back to top