storage: use Update for changeset processing

Batch is only relevant in multithreaded context, internally it'll do some
magic and use the same locking/updating Update does, so it makes little sense
for us. This doesn't change benchmarks in any noticeable way.
This commit is contained in:
Roman Khimov 2022-02-11 16:48:35 +03:00
parent 6380647770
commit a5f8b8870a

View file

@ -92,7 +92,7 @@ func (s *BoltDBStore) PutBatch(batch Batch) error {
func (s *BoltDBStore) PutChangeSet(puts map[string][]byte) error {
var err error
return s.db.Batch(func(tx *bbolt.Tx) error {
return s.db.Update(func(tx *bbolt.Tx) error {
b := tx.Bucket(Bucket)
for k, v := range puts {
if v != nil {