Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parquet Compaction: Restore discarded rows to pool #1692

Merged
merged 2 commits into from
Aug 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
* [ENHANCEMENT] metrics-generator: expose span size as a metric [#1662](https://github.com/grafana/tempo/pull/1662) (@ie-pham)
* [ENHANCEMENT] Set Max Idle connections to 100 for Azure, should reduce DNS errors in Azure [#1632](https://github.com/grafana/tempo/pull/1632) (@electron0zero)
* [CHANGE] Make DNS address fully qualified to reduce DNS lookups in Kubernetes [#1687](https://github.com/grafana/tempo/pull/1687) (@electron0zero)
* [CHANGE] Improve parquet compaction memory profile when dropping spans [#1692](https://github.com/grafana/tempo/pull/1692) (@joe-elliott)

## v1.5.0 / 2022-08-17

Expand Down
5 changes: 3 additions & 2 deletions tempodb/encoding/vparquet/compactor.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,9 @@ func (c *Compactor) Compact(ctx context.Context, l log.Logger, r backend.Reader,
}
if sum > c.opts.MaxBytesPerTrace {
// Trace too large to compact
for _, discardedRow := range rows[1:] {
c.opts.SpansDiscarded(countSpans(sch, discardedRow))
for i := 1; i < len(rows); i++ {
c.opts.SpansDiscarded(countSpans(sch, rows[i]))
pool.Put(rows[i])
}
return rows[0], nil
}
Expand Down