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

release-20.1: changefeedccl: fix memory leak in rowFetcherCache #49161

Merged
merged 1 commit into from
May 17, 2020

Conversation

ajwerner
Copy link
Contributor

Backport 1/1 commits from #49101.

/cc @cockroachdb/release


The rowFetcherCache used by the changefeed to decode KVs into datums
keys the row.Fetcher for a table by using an *ImmutableTableDescriptor.
Unfortunately, over time, as the LeaseManager renews leases, the table
descriptor used to perform the lookup will change. This leads to a slow
leak of a single row.Fetcher every couple of minutes. This ends up
being pretty bad when backfilling a large table as each row.Fetcher ends
up holding onto a whole ScanResponse.

Release note (bug fix): Fix memory leak which can affect CHANGEFEEDs
performing scans of large tables.

The rowFetcherCache used by the changefeed to decode KVs into datums
keys the row.Fetcher for a table by using an `*ImmutableTableDescriptor`.
Unfortunately, over time, as the `LeaseManager` renews leases, the table
descriptor used to perform the lookup will change. This leads to a slow
leak of a single `row.Fetcher` every couple of minutes. This ends up
being pretty bad when backfilling a large table as each row.Fetcher ends
up holding onto a whole `ScanResponse`

Release note (bug fix): Fix memory leak which can affect CHANGEFEEDs
performing scans of large tables.
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@ajwerner ajwerner requested review from pbardea and dt May 16, 2020 23:34
@ajwerner ajwerner merged commit 6bdc5cd into cockroachdb:release-20.1 May 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants