Skip to content
context-engine
Tools

restart_workspace

Restart currently running language servers while preserving workspace state.

restart_workspace stops and restarts the language servers currently running for an active workspace. Context Engine preserves the workspace cache, task state, and handle registry; servers that were not running remain lazy.

Use when

  • A language server has crashed or become unresponsive.
  • A focused retry confirms stale or incorrect LSP-derived results that persist in the running server.

Do not use when

  • You changed .context-engine/config.toml; use reload_config.
  • You only want to initialize another workspace or release an unused one.

Request

{"workspace_root":"/absolute/path/to/repository"}

Parameters

ParameterTypeRequiredDescription
workspace_rootstringYesAbsolute workspace root directory or a file:// URI.

What it returns

The running language servers are stopped, started again, and awaited until ready. Workspace cache, task state, and registered handles remain available; previously lazy servers remain lazy.

Common mistakes

  • Using a relative path or a nested source directory.
  • Expecting configuration changes to apply; restart does not reload .context-engine/config.toml.
  • Restarting before verifying a server problem with a focused retry.
  • reload_config applies configuration changes and selectively restarts affected servers.
  • shutdown_workspace deactivates a workspace and releases its resources.