Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR refactors DCP client configuration to remove the unused GroupID option (using checkpoint prefixes instead) and adjusts .gitignore entries intended to avoid ignoring tool directories.
Changes:
- Remove
GroupIDfrombase.DCPClientOptionsand update DCP option builders/call sites (resync, attachment migration, attachment compaction, cache perf tool). - Update tests that construct DCP client options to no longer pass
groupID. - Modify
.gitignorepatterns related to tool binaries/directories.
Reviewed changes
Copilot reviewed 9 out of 10 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| tools/cache_perf_tool/dcpDataGeneration.go | Stops populating removed DCPClientOptions.GroupID in test client options. |
| db/background_mgr_resync_dcp.go | Removes groupID arg from resync DCP option builder; updates call site and comment. |
| db/background_mgr_resync_dcp_test.go | Updates resync test to match new options builder signature. |
| db/background_mgr_attachment_migration.go | Removes groupID arg from migration DCP option builder; updates call site and comment. |
| db/background_mgr_attachment_migration_test.go | Updates migration test to match new options builder signature. |
| db/attachment_compaction.go | Removes groupID arg from compaction DCP option builder; updates call sites. |
| db/attachment_compaction_test.go | Updates compaction test to match new options builder signature. |
| base/gocb_dcp_feed.go | Stops setting removed DCPClientOptions.GroupID in feed startup options. |
| base/gocb_dcp_client.go | Removes GroupID from DCPClientOptions struct definition. |
| .gitignore | Attempts to refine ignore rules for tool artifacts/directories. |
Comments suppressed due to low confidence (1)
base/gocb_dcp_feed.go:104
StartGocbDCPFeedstill acceptsgroupID, but it’s no longer used after removingGroupIDfromDCPClientOptions. Withunparamenabled in golangci-lint, this is likely to fail lint. Either remove thegroupIDparameter fromStartGocbDCPFeed(and update callers), or explicitly mark it used (e.g._ = groupID) if the signature must remain for compatibility.
options := DCPClientOptions{
MetadataStoreType: metadataStoreType,
DbStats: dbStats,
CollectionIDs: collectionIDs,
AgentPriority: gocbcore.DcpAgentPriorityMed,
CheckpointPrefix: args.CheckpointPrefix,
}
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
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.
This is some refactoring ahead of other DCP changes. The group ID is not used, we only use the checkpoint prefix.
Pre-review checklist
fmt.Print,log.Print, ...)base.UD(docID),base.MD(dbName))docs/apiIntegration Tests
GSI=true,xattrs=truehttps://jenkins.sgwdev.com/job/SyncGatewayIntegration/277/