avoid reload of 'format.json' over the network under normal conditions (#18842)

This commit is contained in:
Harshavardhana
2024-01-23 14:11:46 -08:00
committed by GitHub
parent 961f7dea82
commit 52229a21cb
11 changed files with 124 additions and 44 deletions

View File

@@ -1390,6 +1390,8 @@ func registerStorageRESTHandlers(router *mux.Router, endpointServerPools Endpoin
}
storage := newXLStorageDiskIDCheck(xl, true)
storage.SetDiskID(xl.diskID)
// We do not have to do SetFormatData() since 'xl'
// already captures formatData cached.
globalLocalDrivesMu.Lock()
defer globalLocalDrivesMu.Unlock()