Skip to content
This repository was archived by the owner on Jul 19, 2023. It is now read-only.

Commit cd841cc

Browse files
committed
Correctly log the ReadPages on span
1 parent 7d21d11 commit cd841cc

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

pkg/phlaredb/query/iters.go

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -998,7 +998,7 @@ func (c *SyncIterator) seekPages(seekTo RowNumber, definitionLevel int) (done bo
998998
}
999999
c.metrics.pageReadsTotal.WithLabelValues(c.table, c.columnName).Add(1)
10001000
c.span.LogFields(
1001-
log.String("msg", "reading page"),
1001+
log.String("msg", "reading page (seekPages)"),
10021002
log.Int64("page_num_values", pg.NumValues()),
10031003
log.Int64("page_size", pg.Size()),
10041004
)
@@ -1057,6 +1057,13 @@ func (c *SyncIterator) next() (RowNumber, *parquet.Value, error) {
10571057
if err != nil {
10581058
return EmptyRowNumber(), nil, err
10591059
}
1060+
c.metrics.pageReadsTotal.WithLabelValues(c.table, c.columnName).Add(1)
1061+
c.span.LogFields(
1062+
log.String("msg", "reading page (next)"),
1063+
log.Int64("page_num_values", pg.NumValues()),
1064+
log.Int64("page_size", pg.Size()),
1065+
)
1066+
10601067
if c.filter != nil && !c.filter.KeepPage(pg) {
10611068
// This page filtered out
10621069
c.curr.Skip(pg.NumRows())

0 commit comments

Comments
 (0)