Skip to content

fix: reduce ConfigBuilder::build stack usage#20650

Merged
jif-oai merged 1 commit into
mainfrom
jif/cut-stack
May 1, 2026
Merged

fix: reduce ConfigBuilder::build stack usage#20650
jif-oai merged 1 commit into
mainfrom
jif/cut-stack

Conversation

@jif-oai

@jif-oai jif-oai commented May 1, 2026

Copy link
Copy Markdown
Collaborator

Why

ConfigBuilder::build performs a large amount of async config loading. Leaving that entire future on the caller stack makes config startup more fragile on small runtime worker stacks.

What changed

  • keep ConfigBuilder::build as a thin wrapper that boxes the config-loading future before awaiting it
  • move the existing implementation into a private build_inner method so the large async state machine lives on the heap instead of the runtime thread stack

Testing

  • Not run locally

@jif-oai jif-oai requested a review from a team as a code owner May 1, 2026 18:05
@bolinfest bolinfest self-requested a review May 1, 2026 18:17
@jif-oai jif-oai changed the title fix: cut stack fix: reduce ConfigBuilder::build stack usage May 1, 2026
@jif-oai jif-oai enabled auto-merge (squash) May 1, 2026 18:18
@jif-oai jif-oai disabled auto-merge May 1, 2026 18:24
@jif-oai jif-oai merged commit 2817866 into main May 1, 2026
25 checks passed
@jif-oai jif-oai deleted the jif/cut-stack branch May 1, 2026 18:24
@github-actions github-actions Bot locked and limited conversation to collaborators May 1, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants