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

Improve error handling of local housekeeping and compaction #14947

Open
Tracked by #13982
andrwng opened this issue Nov 14, 2023 · 0 comments
Open
Tracked by #13982

Improve error handling of local housekeeping and compaction #14947

andrwng opened this issue Nov 14, 2023 · 0 comments
Labels
area/storage kind/enhance New feature or request

Comments

@andrwng
Copy link
Contributor

andrwng commented Nov 14, 2023

Currently local segment compaction relies on a mix of early returns and throwing to indicate errors during compaction (e.g. segment was closed during compaction because of a race with prefix truncation). This makes it generally difficult to reason about error scenarios, and functionally makes such error scenarios high cost (e.g. because they may force the housekeeping loop to restart because of the thrown exception).

There are a few possible cleanup options:

  • continue to rely on exceptions, but be more graceful within the housekeeping loop (e.g. wrap compaction methods try/catch, swallow the exceptions, and move on)
  • switch over to using some kind of boost result type and std::error_outcome specific to either compaction or the local storage subsystem at large

JIRA Link: CORE-1575

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/storage kind/enhance New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant