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

Disable autovacuum on compressed hypercore chunk #7358

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

mkindahl
Copy link
Contributor

@mkindahl mkindahl commented Oct 17, 2024

Autovacuum will run on all relations that are not explicitly disabled,
which can lead to unnecessarily vacuuming the compressed relation
twice: once as part of the hypercore table access method and once as a
separate relation.

This commit disables autovacuum_enabled for the compressed chunks
when the main chunk is turned into a hypercore chunk. It deals with
both the cases that you have a partially compressed chunk.

Disable-check: commit-count

Copy link

codecov bot commented Oct 17, 2024

Codecov Report

Attention: Patch coverage is 79.16667% with 10 lines in your changes missing coverage. Please review.

Project coverage is 82.56%. Comparing base (59f50f2) to head (5c63e0c).
Report is 554 commits behind head on main.

Files with missing lines Patch % Lines
src/utils.c 69.69% 3 Missing and 7 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7358      +/-   ##
==========================================
+ Coverage   80.06%   82.56%   +2.49%     
==========================================
  Files         190      229      +39     
  Lines       37181    42767    +5586     
  Branches     9450    10742    +1292     
==========================================
+ Hits        29770    35309    +5539     
- Misses       2997     3169     +172     
+ Partials     4414     4289     -125     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mkindahl mkindahl force-pushed the hypercore-disable-compressed-vacuum branch 6 times, most recently from fd2647a to fea63bd Compare October 18, 2024 13:21
@mkindahl mkindahl marked this pull request as ready for review October 19, 2024 11:23
Autovacuum will run on all relations that are not explicitly disabled,
which can lead to unnecessarily vacuuming the compressed relation
twice: once as part of the hypercore table access method and once as a
separate relation.

This commit disables `autovacuum_enabled` for the compressed chunks
when the main chunk is turned into a hypercore chunk. It deals with
both the cases that you have a partially compressed chunk.
@mkindahl mkindahl force-pushed the hypercore-disable-compressed-vacuum branch from fea63bd to 5c63e0c Compare October 19, 2024 11:24
Copy link
Contributor

@erimatnor erimatnor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it intentional to have the extra commit with review comments included?

If so, it seems unrelated to the main change. Also, I don't think we want a commit in the log that says "Handle review comments." so it is unclear what the intention is here.

As for the main issue you are trying to address, I am wondering if there wasn't some previous way of turning off vacuum? I believe we used to do it for the compressed chunk prior to DML support on compressed data. Isn't there some code to reuse from that functionality?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants