use argon2 with sync.Pool for better memory management (#11019)

This commit is contained in:
Harshavardhana
2020-12-03 19:23:19 -08:00
committed by GitHub
parent de9b64834e
commit e083471ec4
16 changed files with 1174 additions and 22 deletions
+3 -5
View File
@@ -620,11 +620,9 @@ func listIAMConfigItems(ctx context.Context, objAPI ObjectLayer, pathPrefix stri
func (iamOS *IAMObjectStore) watch(ctx context.Context, sys *IAMSys) {
// Refresh IAMSys.
for {
select {
case <-ctx.Done():
return
case <-time.NewTimer(globalRefreshIAMInterval).C:
logger.LogIf(ctx, iamOS.loadAll(ctx, sys))
time.Sleep(globalRefreshIAMInterval)
if err := iamOS.loadAll(ctx, sys); err != nil {
logger.LogIf(ctx, err)
}
}
}