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

pageserver: make local timeline deletion infallible #9594

Merged
merged 3 commits into from
Nov 4, 2024

Conversation

jcsp
Copy link
Contributor

@jcsp jcsp commented Oct 31, 2024

Problem

In #9589, timeline offload code is modified to return an explicit error type rather than propagating anyhow::Error. One of the 'Other' cases there is I/O errors from local timeline deletion, which shouldn't need to exist, because our policy is not to try and continue running if the local disk gives us errors.

Summary of changes

  • Make delete_local_timeline_directory and use .fatal_err( on I/O errors

Checklist before requesting a review

  • I have performed a self-review of my code.
  • If it is a core feature, I have added thorough tests.
  • Do we need to implement analytics? if so did you add the relevant metrics to the dashboard?
  • If this PR requires public announcement, mark it with /release-notes label and add several sentences in this section.

Checklist before merging

  • Do not forget to reformat commit message to not include the above checklist

@jcsp jcsp added c/storage/pageserver Component: storage: pageserver a/tech_debt Area: related to tech debt labels Oct 31, 2024
@jcsp jcsp force-pushed the jcsp/infallible-timeline-delete branch from 9e91f6e to 150b9a8 Compare October 31, 2024 14:04
@jcsp jcsp force-pushed the jcsp/infallible-timeline-delete branch from 150b9a8 to aeb4360 Compare October 31, 2024 14:46
@jcsp jcsp requested a review from erikgrinaker October 31, 2024 14:47
@jcsp
Copy link
Contributor Author

jcsp commented Oct 31, 2024

@erikgrinaker for context, our internal note on infallible local I/O is https://docs.neon.build/storage/handling_io_and_logical_errors.html (not all code respects this yet)

@jcsp jcsp marked this pull request as ready for review October 31, 2024 15:22
@jcsp jcsp requested a review from a team as a code owner October 31, 2024 15:22
Copy link

github-actions bot commented Oct 31, 2024

5354 tests run: 5129 passed, 3 failed, 222 skipped (full report)


Failures on Postgres 17

# Run all failed tests locally:
scripts/pytest -vv -n $(nproc) -k "test_sharding_split_failures[debug-pg17-failure0] or test_sharding_split_failures[debug-pg17-failure12] or test_sharding_split_failures[debug-pg17-failure9]"
Flaky tests (2)

Postgres 17

Code coverage* (full report)

  • functions: 31.5% (7772 of 24690 functions)
  • lines: 48.9% (61030 of 124690 lines)

* collected from Rust tests only


The comment gets automatically updated with the latest test results
4246622 at 2024-11-01T18:38:57.841Z :recycle:

@erikgrinaker
Copy link
Contributor

for context, our internal note on infallible local I/O is https://docs.neon.build/storage/handling_io_and_logical_errors.html (not all code respects this yet)

Makes sense, thanks for the background.

jcsp and others added 2 commits November 1, 2024 12:46
@jcsp jcsp enabled auto-merge (squash) November 1, 2024 15:49
@jcsp jcsp merged commit 4534f5c into main Nov 4, 2024
81 checks passed
@jcsp jcsp deleted the jcsp/infallible-timeline-delete branch November 4, 2024 09:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a/tech_debt Area: related to tech debt c/storage/pageserver Component: storage: pageserver
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants