Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 30 for __construct (0.18 sec)

  1. cmd/erasure-coding.go

    // It returns an error if the decoding failed.
    func (e *Erasure) DecodeDataAndParityBlocks(ctx context.Context, data [][]byte) error {
    	return e.encoder().Reconstruct(data)
    }
    
    // ShardSize - returns actual shared size from erasure blockSize.
    func (e *Erasure) ShardSize() int64 {
    	return ceilFrac(e.blockSize, int64(e.dataBlocks))
    }
    
    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)
  2. cmd/bucket-policy-handlers_test.go

    	for i, testCase := range testCases {
    		// obtain the put bucket policy request body.
    		// initialize HTTP NewRecorder, this records any mutations to response writer inside the handler.
    		recV4 := httptest.NewRecorder()
    		// construct HTTP request for PUT bucket policy endpoint.
    		reqV4, err := newTestSignedRequestV4(http.MethodPut, getPutPolicyURL("", testCase.bucketName),
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Jan 18 07:03:17 GMT 2024
    - 32.7K bytes
    - Viewed (0)
  3. cmd/object-handlers_test.go

    	for i, testCase := range testCases {
    		// initialize HTTP NewRecorder, this records any mutations to response writer inside the handler.
    		rec := httptest.NewRecorder()
    		// construct HTTP request for Get Object end point.
    		req, err := newTestSignedRequestV4(http.MethodHead, getHeadObjectURL("", testCase.bucketName, testCase.objectName),
    			0, nil, testCase.accessKey, testCase.secretKey, nil)
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 160K bytes
    - Viewed (0)
  4. cni/pkg/repair/repair.go

    		repairLog.Info("CNI repair is disable.")
    		return
    	}
    	repairLog.Info("Start CNI race condition repair.")
    
    	client, err := clientSetup()
    	if err != nil {
    		repairLog.Fatalf("CNI repair could not construct clientSet: %s", err)
    	}
    
    	rc, err := NewRepairController(client, cfg)
    	if err != nil {
    		repairLog.Fatalf("Fatal error constructing repair controller: %+v", err)
    	}
    	go rc.Run(ctx.Done())
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Tue May 23 17:08:31 GMT 2023
    - 1.5K bytes
    - Viewed (0)
  5. cmd/signature-v4.go

    		return ErrExpiredPresignRequest
    	}
    
    	// Save the date and expires.
    	t := pSignValues.Date
    	expireSeconds := int(pSignValues.Expires / time.Second)
    
    	// Construct new query.
    	query := make(url.Values)
    	clntHashedPayload := req.Form.Get(xhttp.AmzContentSha256)
    	if clntHashedPayload != "" {
    		query.Set(xhttp.AmzContentSha256, hashedPayload)
    	}
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 19 16:45:54 GMT 2024
    - 12.3K bytes
    - Viewed (0)
  6. cmd/erasure-decode.go

    			return -1, err
    		}
    
    		bytesWritten += n
    	}
    
    	if bytesWritten != length {
    		return bytesWritten, errLessData
    	}
    
    	return bytesWritten, derr
    }
    
    // Heal reads from readers, reconstruct shards and writes the data to the writers.
    func (e Erasure) Heal(ctx context.Context, writers []io.Writer, readers []io.ReaderAt, totalLength int64, prefer []bool) (derr error) {
    	if len(writers) != e.parityBlocks+e.dataBlocks {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 19 16:44:59 GMT 2024
    - 9.4K bytes
    - Viewed (0)
  7. cmd/admin-handlers_test.go

    	queryVal := url.Values{}
    	queryVal.Set("info", "")
    
    	req, err := buildAdminRequest(queryVal, http.MethodGet, "/info", 0, nil)
    	if err != nil {
    		t.Fatalf("Failed to construct get-config object request - %v", err)
    	}
    
    	rec := httptest.NewRecorder()
    	adminTestBed.router.ServeHTTP(rec, req)
    	if rec.Code != http.StatusOK {
    		t.Errorf("Expected to succeed but failed with %d", rec.Code)
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Feb 22 06:26:06 GMT 2024
    - 13.8K bytes
    - Viewed (0)
  8. internal/bucket/object/lock/lock.go

    		return ObjectLegalHold{XMLNS: "http://s3.amazonaws.com/doc/2006-03-01/", Status: parseLegalHoldStatus(holdStr)}
    	}
    	return ObjectLegalHold{}
    }
    
    // ParseObjectLockLegalHoldHeaders parses request headers to construct ObjectLegalHold
    func ParseObjectLockLegalHoldHeaders(h http.Header) (lhold ObjectLegalHold, err error) {
    	holdStatus, ok := h[AmzObjectLockLegalHold]
    	if ok {
    		lh := parseLegalHoldStatus(holdStatus[0])
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 17.1K bytes
    - Viewed (0)
  9. cmd/bucket-handlers_test.go

    	if err != nil {
    		t.Fatalf("Error uploading object: <ERROR> %v", err)
    	}
    
    	// initialize httptest Recorder, this records any mutations to response writer inside the handler.
    	rec := httptest.NewRecorder()
    	// construct HTTP request for DELETE bucket.
    	req, err := newTestSignedRequestV4(http.MethodDelete, getBucketLocationURL("", bucketName), 0, nil, credentials.AccessKey, credentials.SecretKey, nil)
    	if err != nil {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Feb 22 06:26:06 GMT 2024
    - 39.5K bytes
    - Viewed (2)
  10. cmd/data-scanner.go

    				}
    				return nil
    			}
    
    			// successfully read means we have a valid object.
    			foundObjects = true
    			// Remove filename i.e is the meta file to construct object name
    			item.transformMetaDir()
    
    			// Object already accounted for, remove from heal map,
    			// simply because getSize() function already heals the
    			// object.
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Apr 22 17:49:30 GMT 2024
    - 47.4K bytes
    - Viewed (0)
Back to top