Own Companion services in an application instance - #34
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
0402a6a to
1916b54
Compare
1916b54 to
8bd3474
Compare
8bd3474 to
790edef
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 790edefe01
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
790edef to
df30a1b
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: df30a1b9ad
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
c791ad1 to
6971f28
Compare
6971f28 to
14a655b
Compare
Took 2 minutes Took 2 minutes
# Commit time for manual adjustment: # Took 1 second
14a655b to
be80e56
Compare
Companion services now belong to a CompanionApplication instance. CompanionApp retains the process entrypoint, launch lock, logging and look-and-feel setup. MainWindow is constructed explicitly and communicates with application lifecycle through CompanionUi; the singleton window and production configureWithoutSession test path are removed.
MCP and session callbacks use the application instance. Window publication replays current project and service state, deferred navigation stays with its project, and queued UI notifications validate their captured window. Obsolete service-locator getters were deleted. JDT initialization receives an explicit metadata path; its process globals remain deliberate, with one test cache per JVM. Parser prewarming uses the existing project worker.
Lifecycle, runtime-installation and script-panel disposal tests now run in-process without reflecting on application globals. Actual JDWP debuggee forks remain. The UI harness constructs and closes a real application.
Validation: full
:check :localBundle --warning-mode failwith offline local Maven dependencies passed; UI harness rendering inspected. Added deferred-frame navigation and late runtime refresh coverage. Lifecycle tests await lookup entry and socket teardown callbacks explicitly. Independent spec/standards findings are addressed.Stacked on #33. Editor-owned ASTCache and EDT helper cleanup continue in #35.
Window initialization and queued-navigation capture complete before UI publication under the lifecycle lock, without a synchronous Swing hop or future join under that lock. Window disposal unregisters status-bar and evaluation-dialog theme listeners. Regressions cover repeated application lifecycles, rejected window creation and request rejection during replacement restoration. Pure Swing startup remains in CompanionApp.
CompanionApplication remains above the plan's roughly 500-line revisit threshold. A future split is deferred; this PR introduces no additional service layers.
Review notes:
CompanionApplicationis about 760 lines, above the plan's ~500-line threshold for revisiting a layered split. Roughly 120 of those lines are service-status literals and MCP start/stop wiring; the split stays future work and is not part of this stack.