v1 backport pr 1798 v1#1834
Merged
Merged
Conversation
* Initial plan * Add AofSegmentSize option and apply it to TsavoriteLogSettings Agent-Logs-Url: https://github.com/microsoft/garnet/sessions/cc0abf6b-ee36-45e2-8578-3c89663bdc1b Co-authored-by: badrishc <[email protected]> * Validate AOF sizes before allocating devices to avoid handle leak Agent-Logs-Url: https://github.com/microsoft/garnet/sessions/172f9b38-65ea-4ef5-acee-e348757c9259 Co-authored-by: badrishc <[email protected]> * Dispose LogCommitManager + use try/finally in AOF segment-size test Agent-Logs-Url: https://github.com/microsoft/garnet/sessions/ffdda9db-bb9a-4574-a510-c52b3647caf3 Co-authored-by: badrishc <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: badrishc <[email protected]> Co-authored-by: Badrish Chandramouli <[email protected]> (cherry picked from commit 4cc403f)
Contributor
There was a problem hiding this comment.
Pull request overview
Backport of PR #1798 to ensure AOF truncation honors the configured Tsavorite log segment size by introducing and plumbing a new AofSegmentSize configuration option through to TsavoriteLogSettings.SegmentSizeBits.
Changes:
- Add
AofSegmentSizeconfig option (CLI + defaults) and flow it intoTsavoriteLogSettings.SegmentSizeBits. - Validate AOF page/memory/segment size relationships before allocating AOF devices/commit managers.
- Update docs and add a config test to cover default/override/validation behavior.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
website/docs/getting-started/configuration.md |
Documents the new --aof-segment-size option in the configuration table. |
Version.props |
Bumps VersionPrefix to 1.1.10. |
test/Garnet.test/GarnetServerConfigTests.cs |
Adds coverage to ensure AofSegmentSize propagates to Tsavorite settings and validates page > segment. |
libs/server/Servers/GarnetServerOptions.cs |
Introduces AofSegmentSize, plumbs segment size bits into AOF log settings, and adds upfront validation. |
libs/host/defaults.conf |
Adds default "AofSegmentSize": "1g" to ensure a stable default. |
libs/host/Configuration/Options.cs |
Adds CLI option wiring for --aof-segment-size and maps it into GarnetServerOptions. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
vazois
approved these changes
May 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #1798