volume server: rename readBufferSize to readBufferSizeMB

This commit is contained in:
chrislu committed 2022-09-17 10:56:28 -07:00
1 parent 3fc261d27c
commit 10d5b4b32b
4 files changed
+8 -8

No files matched your search

+3 -3
View File
@@ -29,7 +29,7 @@ type VolumeServer struct {
inFlightDownloadDataLimitCond *sync.Cond
inflightUploadDataTimeout time.Duration
hasSlowRead bool
readBufferSize int
readBufferSizeMB int
SeedMasterNodes []pb.ServerAddress
currentMaster pb.ServerAddress
@@ -67,7 +67,7 @@ func NewVolumeServer(adminMux, publicMux *http.ServeMux, ip string,
concurrentDownloadLimit int64,
inflightUploadDataTimeout time.Duration,
hasSlowRead bool,
readBufferSize int,
readBufferSizeMB int,
) *VolumeServer {
v := util.GetViper()
@@ -98,7 +98,7 @@ func NewVolumeServer(adminMux, publicMux *http.ServeMux, ip string,
concurrentDownloadLimit: concurrentDownloadLimit,
inflightUploadDataTimeout: inflightUploadDataTimeout,
hasSlowRead: hasSlowRead,
readBufferSize: readBufferSize,
readBufferSizeMB: readBufferSizeMB,
}
vs.SeedMasterNodes = masterNodes
+1 -1
View File
@@ -118,7 +118,7 @@ func (vs *VolumeServer) GetOrHeadHandler(w http.ResponseWriter, r *http.Request)
readOption := &storage.ReadOption{
ReadDeleted: r.FormValue("readDeleted") == "true",
HasSlowRead: vs.hasSlowRead,
ReadBufferSize: vs.readBufferSize,
ReadBufferSize: vs.readBufferSizeMB * 1024 * 1024,
}
var count int