Skip to content

db/state: encapsulate worker state into 1 struct#21075

Merged
AskAlexSharov merged 8 commits into
mainfrom
db/state-agg-workers-refactor
May 13, 2026
Merged

db/state: encapsulate worker state into 1 struct#21075
AskAlexSharov merged 8 commits into
mainfrom
db/state-agg-workers-refactor

Conversation

@AskAlexSharov

Copy link
Copy Markdown
Collaborator

Summary

  • Extract merge, collateAndBuild, allowEditing, and the mutex from Aggregator into a new aggWorkers value type
  • Public Set*Workers methods become unexported helpers (setCompressWorkers, setBuildAccessorsWorkers); the merge/collate counts are accessed via workers.getMerge() / workers.setMerge() etc.
  • Remove the now-unused SetCollateAndBuildWorkers / SetMergeWorkers / SetCompressWorkers stubs from ForkableAgg

No behaviour change — this is a structural cleanup follow-up to #21062.

Extract the workers mutex, allowEditing flag, merge count, and
collateAndBuild count from Aggregator into a self-contained aggWorkers
type. Public Set*Workers methods become private helpers; ForkableAgg
drops its now-unused Set*Workers stubs.
@AskAlexSharov AskAlexSharov changed the title db/state: encapsulate worker state into aggWorkers struct db/state: encapsulate worker state into 1 struct May 9, 2026
@AskAlexSharov

Copy link
Copy Markdown
Collaborator Author

@sudeepdino008 cr plz

@AskAlexSharov AskAlexSharov enabled auto-merge May 13, 2026 12:02
@AskAlexSharov AskAlexSharov added this pull request to the merge queue May 13, 2026
Merged via the queue into main with commit cda9b85 May 13, 2026
67 checks passed
@AskAlexSharov AskAlexSharov deleted the db/state-agg-workers-refactor branch May 13, 2026 19:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants