Skip to content

Commit dcfb296

Browse files
committed
Prevent WritesOff from hanging when the change stream has failed.
1 parent c0c8966 commit dcfb296

File tree

2 files changed

+154
-234
lines changed

2 files changed

+154
-234
lines changed

internal/verifier/check.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,9 @@ func (verifier *Verifier) CheckDriver(ctx context.Context, filter map[string]any
236236
// paying attention. Also, this should not matter too much because any failures will be
237237
// caught again on the next iteration.
238238
if verifier.writesOff {
239+
verifier.logger.Debug().
240+
Msg("Waiting for change stream to end.")
241+
239242
// It's necessary to wait for the change stream to finish before incrementing the
240243
// generation number, or the last changes will not be checked.
241244
verifier.mux.Unlock()

0 commit comments

Comments
 (0)