- Sort Score
- Num 10 results
- Language All
Results 1 - 3 of 3 for toAdminAPIErrCode (0.07 seconds)
-
cmd/admin-handler-utils.go
HTTPStatusCode: http.StatusBadRequest, } default: apiErr = errorCodes.ToAPIErrWithErr(toAdminAPIErrCode(ctx, err), err) } } return apiErr } // toAdminAPIErrCode - converts errErasureWriteQuorum error to admin API // specific error. func toAdminAPIErrCode(ctx context.Context, err error) APIErrorCode { if errors.Is(err, errErasureWriteQuorum) { return ErrAdminConfigNoQuorum }
Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Wed Jul 03 07:17:20 GMT 2024 - 8.4K bytes - Click Count (0) -
cmd/admin-handlers_test.go
} if results.Region != globalMinioDefaultRegion { t.Errorf("Expected %s, got %s", globalMinioDefaultRegion, results.Region) } } // TestToAdminAPIErrCode - test for toAdminAPIErrCode helper function. func TestToAdminAPIErrCode(t *testing.T) { testCases := []struct { err error expectedAPIErr APIErrorCode }{ // 1. Server not in quorum. {Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 13.9K bytes - Click Count (1) -
cmd/admin-heal-ops.go
if !exists { // heal sequence doesn't exist, must have finished. jbytes, err := json.Marshal(healSequenceStatus{ Summary: healFinishedStatus, }) return jbytes, toAdminAPIErrCode(GlobalContext, err) } // Check if client-token is valid if clientToken != h.clientToken { return nil, ErrHealInvalidClientToken } // Take lock to access and update the heal-sequenceCreated: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 25.4K bytes - Click Count (0)