Skip to content

Commit

Permalink
Add a error verification when failed list error is from context canceled
Browse files Browse the repository at this point in the history
Signed-off-by: Vitor Savian <[email protected]>
  • Loading branch information
vitorsavian committed Mar 26, 2024
1 parent 774b2e8 commit 62fa77a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/logstructured/sqllog/sql.go
Original file line number Diff line number Diff line change
Expand Up @@ -432,7 +432,9 @@ func (s *SQLLog) poll(result chan interface{}, pollStart int64) {

rows, err := s.d.After(s.ctx, "%", s.currentRev, pollBatchSize)
if err != nil {
logrus.Errorf("fail to list latest changes: %v", err)
if !errors.Is(err, context.Canceled) {
logrus.Errorf("fail to list latest changes: %v", err)
}
continue
}

Expand Down

0 comments on commit 62fa77a

Please sign in to comment.