forked from TrueCloudLab/frostfs-node
[#259] innerring: Use blocking pools for audit
Audit task manager should not discard tasks if all workers are busy, therefore pools should not be non-blocking. Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This commit is contained in:
parent
3ec342b2c3
commit
f9e81383ae
1 changed files with 2 additions and 2 deletions
|
@ -207,7 +207,7 @@ func New(ctx context.Context, log *zap.Logger, cfg *viper.Viper) (*Server, error
|
|||
|
||||
server.pubKey = crypto.MarshalPublicKey(&server.key.PublicKey)
|
||||
|
||||
auditPool, err := ants.NewPool(cfg.GetInt("audit.task.exec_pool_size"), ants.WithNonblocking(true))
|
||||
auditPool, err := ants.NewPool(cfg.GetInt("audit.task.exec_pool_size"))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
@ -234,7 +234,7 @@ func New(ctx context.Context, log *zap.Logger, cfg *viper.Viper) (*Server, error
|
|||
audittask.WithContainerCommunicator(clientCache),
|
||||
audittask.WithMaxPDPSleepInterval(cfg.GetDuration("audit.pdp.max_sleep_interval")),
|
||||
audittask.WithPDPWorkerPoolGenerator(func() (util2.WorkerPool, error) {
|
||||
return ants.NewPool(pdpPoolSize, ants.WithNonblocking(true))
|
||||
return ants.NewPool(pdpPoolSize)
|
||||
}),
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in a new issue