Repository navigation
Conversation
Redocly previews |
Contributor
|
Droid finished @RIT3shSapata's task —— View job This PR is small and the plumbing for the new config flag looks straightforward. The main issue is that the OpenAPI schema text for |
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Runtime configuration can report a stale partition window after refresh, and the new flag lacks focused regression coverage.
1 open issue
What changed in this PR
Adds an opt-in channel history compaction setting to Sync Gateway; document-write compaction remains deferred.
Changes:
- Adds the configuration flag, defaulting to false, and maps it into database options.
- Documents the new setting.
- Includes #8942’s purge-interval-based client partition defaults and runtime reporting tests.
| File | Description |
|---|---|
| rest/server_context.go | Maps configuration into database options. |
| rest/config.go | Defines the flag and updates partition-window documentation. |
| rest/config_database.go | Adds defaults and runtime window population. |
| rest/config_database_test.go | Allows the dynamically determined window default. |
| rest/api_test.go | Tests partition-window configuration reporting. |
| rest/admin_api.go | Populates runtime partition-window responses. |
| docs/api/components/schemas.yaml | Documents configuration options and defaults. |
| db/database.go | Adds the flag and purge-interval-based window resolution. |
| base/constants.go | Clarifies the test-only window default comment. |
Review effort: Balanced
| DisablePublicAllDocs: disablePublicAllDocs, | ||
| StoreLegacyRevTreeData: new(base.ValDefault(config.StoreLegacyRevTreeData, db.DefaultStoreLegacyRevTreeData)), | ||
| UseSystemMetadataCollection: useMobileCollection, | ||
| EnableChannelHistoryCompaction: base.ValDefault(config.EnableChannelHistoryCompaction, DefaultEnableChannelHistoryCompaction), |
RIT3shSapata
force-pushed
the
CBG-5980
branch
from
October 21, 2026 08:03
436e4c6 to
4cca0e8
Compare
RIT3shSapata
force-pushed
the
CBG-5979
branch
from
October 21, 2026 08:04
f47823a to
5db813c
Compare
RIT3shSapata
force-pushed
the
CBG-5979
branch
from
October 21, 2026 11:29
5db813c to
7c34e38
Compare
bbrks
approved these changes
Oct 22, 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.

CBG-5979
Add the
enable_channel_history_compactiondatabase configuration option, with a default offalse. This PR only adds the option.EnableChannelHistoryCompactiontoDbConfigandDatabaseContextOptions, and map it indbcOptionsFromConfig.DefaultDbConfig, so_config?include_runtime=trueshowsfalsewhen the option is not set.validateChangeshas no rule for it.Databaseschema indocs/api.Pre-review checklist
base.UD(docID),base.MD(dbName))docs/apiDependencies (if applicable)
Integration Tests