mirror of
https://github.com/minio/minio
synced 2024-10-04 15:09:36 +00:00
fix: disable site network test if site replication is disabled (#17579)
This commit is contained in:
parent
8af0773baf
commit
c47ff44f5e
|
@ -1164,6 +1164,11 @@ func (a adminAPIHandlers) SitePerfHandler(w http.ResponseWriter, r *http.Request
|
|||
return
|
||||
}
|
||||
|
||||
if !globalSiteReplicationSys.isEnabled() {
|
||||
writeErrorResponseJSON(ctx, w, errorCodes.ToAPIErr(ErrNotImplemented), r.URL)
|
||||
return
|
||||
}
|
||||
|
||||
nsLock := objectAPI.NewNSLock(minioMetaBucket, "site-net-perf")
|
||||
lkctx, err := nsLock.GetLock(ctx, globalOperationTimeout)
|
||||
if err != nil {
|
||||
|
|
Loading…
Reference in a new issue