Skip to content

fix: keep an in-flight restart attempt alive on start() - #1677

Merged
angelozerr merged 1 commit into
redhat-developer:mainfrom
StephanWald:fix/1673-keep-inflight-restart
Sep 26, 2026
Merged

angelozerr merged 1 commit into
redhat-developer:mainfrom
StephanWald:fix/1673-keep-inflight-restart

Conversation

@StephanWald

Copy link
Copy Markdown
Contributor

While serverError is set, every LanguageServerWrapper.start() call stopped the server and launched a new attempt. serverError is only cleared once an attempt finishes initializing, so repeated start() calls (e.g. one per Search Everywhere keystroke) killed the still-initializing retry, spawned another process each time and used up the restart attempts.

Return early from start() while a restart attempt is initializing. The restart policy itself (up to MAX_NUMBER_OF_RESTART_ATTEMPTS) is unchanged.

Fixes #1673

While serverError is set, every LanguageServerWrapper.start() call stopped
the server and launched a new attempt. serverError is only cleared once an
attempt finishes initializing, so repeated start() calls (e.g. one per
Search Everywhere keystroke) killed the still-initializing retry, spawned
another process each time and used up the restart attempts.

Return early from start() while a restart attempt is initializing. The
restart policy itself (up to MAX_NUMBER_OF_RESTART_ATTEMPTS) is unchanged.

Fixes redhat-developer#1673

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Signed-off-by: Stephan Wald <[email protected]>
@angelozerr

Copy link
Copy Markdown
Contributor

LGTM. Thanks @StephanWald !

@angelozerr
angelozerr merged commit 2dbaa59 into redhat-developer:main Sep 26, 2026
6 checks passed
@lagergren lagergren added this to the 0.30.0 milestone Nov 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

3 participants