Skip to content

Commit

Permalink
Send initialized event, after initialization (eclipse-che#9776)
Browse files Browse the repository at this point in the history
* Send initialized event, after initialization

Signed-off-by: Vitalii Parfonov <vparfonov@redhat.com>
  • Loading branch information
vparfonov authored and hbhargav committed Dec 4, 2018
1 parent 87bbf19 commit 7d809a2
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
import org.eclipse.che.commons.lang.concurrent.LoggingUncaughtExceptionHandler;
import org.eclipse.lsp4j.InitializeParams;
import org.eclipse.lsp4j.InitializeResult;
import org.eclipse.lsp4j.InitializedParams;
import org.eclipse.lsp4j.ServerCapabilities;
import org.eclipse.lsp4j.services.LanguageServer;
import org.slf4j.Logger;
Expand Down Expand Up @@ -141,6 +142,7 @@ CompletableFuture<ServerCapabilities> initialize(String wsPath) {
executor);
}


private String initializeIOStreams(String id) {
try {
LOG.debug("Initializing of IO streams for server '{}': started", id);
Expand Down Expand Up @@ -216,6 +218,7 @@ private String initializeServerInstance(String id) {
LOG.debug("Initializing of a language server instance for server '{}': finished", id);

LOG.info("Initialized language server '{}'", id);
languageServer.initialized(new InitializedParams());//send initialized message, some LS required it
return serverCapabilitiesRegistry.add(id, initializeResult.getCapabilities());
}
} catch (LanguageServerException
Expand Down

0 comments on commit 7d809a2

Please sign in to comment.