Fix minimum replication workers started (#10560)

This PR also fixes GetReplicationConfiguration permission
in web-handlers.go to use bucket as resource
This commit is contained in:
poornas
2020-09-24 12:25:41 -07:00
committed by GitHub
parent ca989eb0b3
commit e6ab4db6b8
3 changed files with 8 additions and 1 deletions

View File

@@ -304,6 +304,11 @@ var (
)
func newReplicationState() *replicationState {
// fix minimum concurrent replication to 1 for single CPU setup
if globalReplicationConcurrent == 0 {
globalReplicationConcurrent = 1
}
rs := &replicationState{
replicaCh: make(chan ObjectInfo, globalReplicationConcurrent*2),
}

View File

@@ -1025,7 +1025,7 @@ func (web *webAPIHandlers) Upload(w http.ResponseWriter, r *http.Request) {
BucketName: bucket,
ConditionValues: getConditionValues(r, "", claims.AccessKey, claims.Map()),
IsOwner: owner,
ObjectName: object,
ObjectName: "",
Claims: claims.Map(),
}) {
replPerms = ErrNone