Fixups after rebase

Signed-off-by: Thomas Mäder <tmader@redhat.com>
6.19.x
Thomas Mäder 2018-06-04 11:33:34 +02:00 committed by Thomas Mäder
parent 8020d11686
commit bdf9fa5a9c
14 changed files with 85 additions and 11 deletions

View File

@ -16,7 +16,7 @@
<parent>
<artifactId>che-agents-parent</artifactId>
<groupId>org.eclipse.che</groupId>
<version>6.6.0-SNAPSHOT</version>
<version>6.7.0-SNAPSHOT</version>
</parent>
<artifactId>ls-java-agent</artifactId>
<name>Language Server Java Agent</name>

View File

@ -131,8 +131,10 @@ WORKSPACE_MASTER_URI=$(echo $CHE_API | cut -d / -f 1-3)
## Evaluate variables now that prefix is defined
eval "DOWNLOAD_AGENT_BINARIES_URI=${DOWNLOAD_AGENT_BINARIES_URI}"
echo Downloading java LS
curl -sL ${DOWNLOAD_AGENT_BINARIES_URI} | tar xzf - -C ${LS_DIR}
echo writing start script to ${LS_LAUNCHER}
touch ${LS_LAUNCHER}
chmod +x ${LS_LAUNCHER}
echo "java -Declipse.application=org.eclipse.jdt.ls.core.id1 -Dosgi.bundles.defaultStartLevel=4 -Declipse.product=org.eclipse.jdt.ls.core.product -noverify -Xmx1G -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=4410 -jar ${LS_DIR}/plugins/org.eclipse.equinox.launcher_1.5.0.v20180207-1446.jar -configuration ./config_linux -data ${LS_DIR}/data" > ${LS_LAUNCHER}
echo "java -Declipse.application=org.eclipse.jdt.ls.core.id1 -Dosgi.bundles.defaultStartLevel=4 -Declipse.product=org.eclipse.jdt.ls.core.product -noverify -Xmx1G -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=4410 -jar ${LS_DIR}/plugins/org.eclipse.equinox.launcher_1.5.0.v20180512-1130.jar -configuration ./config_linux -data ${LS_DIR}/data" > ${LS_LAUNCHER}

View File

@ -23,6 +23,10 @@
<packaging>jar</packaging>
<name>Che Plugin :: Java :: Eclipse JDT UI</name>
<dependencies>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
</dependency>
<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
@ -47,6 +51,10 @@
<groupId>org.eclipse.birt.runtime</groupId>
<artifactId>org.eclipse.equinox.common</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-core</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-dto</artifactId>
@ -63,6 +71,10 @@
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-project-shared</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-commons-annotations</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-commons-lang</artifactId>

View File

@ -61,6 +61,10 @@
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-dto</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-model</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-project</artifactId>

View File

@ -0,0 +1,37 @@
/*
* Copyright (c) 2012-2018 Red Hat, Inc.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Red Hat, Inc. - initial API and implementation
*/
package org.eclipse.che.ide.ext.java.shared.dto;
import java.util.List;
import org.eclipse.che.dto.shared.DTO;
/** @author Evgen Vidolob */
@DTO
public interface ReconcileResult {
List<Problem> getProblems();
void setProblems(List<Problem> problems);
ReconcileResult withProblems(List<Problem> problems);
List<HighlightedPosition> getHighlightedPositions();
void setHighlightedPositions(List<HighlightedPosition> positions);
ReconcileResult withHighlightedPositions(List<HighlightedPosition> positions);
String getFileLocation();
void setFileLocation(String path);
ReconcileResult withFileLocation(String path);
}

View File

@ -29,8 +29,8 @@ import org.eclipse.che.api.core.NotFoundException;
import org.eclipse.che.api.core.ServerException;
import org.eclipse.che.api.project.server.ProjectManager;
import org.eclipse.che.api.project.server.impl.NewProjectConfigImpl;
import org.eclipse.che.api.project.server.impl.RegisteredProject;
import org.eclipse.che.api.project.shared.NewProjectConfig;
import org.eclipse.che.api.project.shared.RegisteredProject;
import org.eclipse.che.jdt.ls.extension.api.dto.ClasspathEntry;
import org.eclipse.che.plugin.java.languageserver.JavaLanguageServerExtensionService;

View File

@ -16,7 +16,7 @@
<parent>
<artifactId>che-plugin-java-parent</artifactId>
<groupId>org.eclipse.che.plugin</groupId>
<version>6.6.0-SNAPSHOT</version>
<version>6.7.0-SNAPSHOT</version>
</parent>
<artifactId>che-plugin-java-server</artifactId>
<name>Che Plugin :: Java :: Language Server</name>
@ -65,10 +65,19 @@
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-languageserver</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-languageserver-shared</artifactId>
<version>6.7.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-project</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-project-shared</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-workspace</artifactId>

View File

@ -22,8 +22,8 @@ import org.eclipse.che.api.core.NotFoundException;
import org.eclipse.che.api.core.ServerException;
import org.eclipse.che.api.core.notification.EventService;
import org.eclipse.che.api.project.server.ProjectManager;
import org.eclipse.che.api.project.server.impl.RegisteredProject;
import org.eclipse.che.api.project.server.notification.ProjectUpdatedEvent;
import org.eclipse.che.api.project.shared.RegisteredProject;
import org.eclipse.che.api.workspace.server.model.impl.ProjectConfigImpl;
import org.eclipse.che.api.workspace.server.model.impl.SourceStorageImpl;
import org.slf4j.Logger;

View File

@ -71,6 +71,10 @@
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-project</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-project-shared</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-commons-inject</artifactId>
@ -79,6 +83,10 @@
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-commons-lang</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-commons-schedule</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-commons-xml</artifactId>

View File

@ -34,10 +34,6 @@
<groupId>javax.inject</groupId>
<artifactId>javax.inject</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-project</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.che.core</groupId>
<artifactId>che-core-api-testing</artifactId>

View File

@ -20,7 +20,6 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
import java.util.regex.Pattern;
import javax.annotation.PostConstruct;
import javax.inject.Inject;
import javax.inject.Singleton;
import org.eclipse.che.api.languageserver.LanguageServerConfig.CommunicationProvider;
@ -60,7 +59,6 @@ class LanguageServerConfigInitializer {
this.languageFilterRegistry = registryContainer.languageFilterRegistry;
}
@PostConstruct
void initialize() {
LOG.info("Language server config processing: started");
for (LanguageServerConfigProvider provider : providers) {

View File

@ -65,8 +65,11 @@ public class LanguageServerInitializer {
private final Registry<Pair<InputStream, OutputStream>> ioStreamRegistry;
private final Registry<CommunicationProvider> communicationProviderRegistry;
private LanguageServerConfigInitializer configInitializer;
@Inject
public LanguageServerInitializer(
LanguageServerConfigInitializer configInitializer,
ServerCapabilitiesAccumulator serverCapabilitiesAccumulator,
RegistryContainer registryContainer,
FindId findId,
@ -75,6 +78,7 @@ public class LanguageServerInitializer {
InitializeParamsProvider initializeParamsProvider) {
this.executor = newCachedThreadPool(getFactory());
this.configInitializer = configInitializer;
this.eventService = eventService;
this.cheLanguageClientFactory = cheLanguageClientFactory;
this.initializeParamsProvider = initializeParamsProvider;
@ -112,6 +116,7 @@ public class LanguageServerInitializer {
() -> {
LOG.info("Started language servers initialization, file path '{}'", wsPath);
configInitializer.initialize();
Set<ServerCapabilities> serverCapabilitiesSet =
findId
.byPath(wsPath)

View File

@ -27,12 +27,14 @@ public class LanguageServerModule extends AbstractModule {
@Override
protected void configure() {
bind(RegistryContainer.class).asEagerSingleton();
bind(WorkspaceService.class).asEagerSingleton();
bind(TextDocumentService.class).asEagerSingleton();
bind(PublishDiagnosticsParamsJsonRpcTransmitter.class).asEagerSingleton();
bind(ShowMessageJsonRpcTransmitter.class).asEagerSingleton();
bind(LanguageServerConfigInitializer.class).asEagerSingleton();
bind(LanguageServerService.class).asEagerSingleton();
bind(LanguageServerInitializer.class).asEagerSingleton();
install(new FactoryModuleBuilder().build(CheLanguageClientFactory.class));

View File

@ -30,6 +30,7 @@ import org.eclipse.che.api.fs.server.FsManager;
import org.eclipse.che.api.project.server.handlers.ProjectInitHandler;
import org.eclipse.che.api.project.server.notification.BeforeProjectInitializedEvent;
import org.eclipse.che.api.project.server.notification.ProjectInitializedEvent;
import org.eclipse.che.api.project.shared.RegisteredProject;
import org.eclipse.che.api.search.server.excludes.HiddenItemPathMatcher;
@Singleton