Skip to content

Commit 5a83763

Browse files
committed
Merge commit '52b05be05d5439239eb6d4386922f669336b7774' into alex/suggestions2_stored-chunk-data-pack
2 parents 629da34 + 52b05be commit 5a83763

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

storage/store/chunk_data_packs.go

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -143,12 +143,7 @@ func (ch *ChunkDataPacks) Store(cs []*flow.ChunkDataPack) (
143143
storeChunkDataPacksFunc := func(lctx lockctx.Proof, protocolDBBatch storage.ReaderBatchWriter) error {
144144
protocolDBBatch.AddCallback(func(err error) {
145145
if err != nil {
146-
log.Warn().Err(err).Msgf("batch operation failed, rolling back stored chunk data packs for chunks: %v", cs)
147-
// Rollback the stored chunk data packs if the batch operation fails
148-
err := ch.stored.Remove(chunkDataPackIDs) // rollback stored chunk data packs on failure
149-
if err != nil {
150-
log.Fatal().Err(err).Msgf("cannot rollback stored chunk data packs") // log the error, but do not override the original error
151-
}
146+
log.Warn().Err(err).Msgf("indexing chunkID -> chunkDataPackID mapping failed, chunkDataPackIDs: %v", chunkDataPackIDs)
152147
}
153148
})
154149

0 commit comments

Comments
 (0)