che-server/samples/sample-plugin-serverservice
Artem Zatsarynnyi cce79bf469 Merge branch 'master' into spi
# Conflicts:
#	assembly/assembly-wsmaster-war/pom.xml
#	infrastructures/docker/pom.xml
#	plugins/plugin-docker/che-plugin-docker-compose/pom.xml
#	plugins/plugin-github/che-plugin-github-pullrequest/src/main/java/org/eclipse/che/plugin/pullrequest/client/GitHubHostingService.java
#	plugins/plugin-testing-java/plugin-testing-junit/che-plugin-testing-junit-ide/src/main/java/org/eclipse/che/plugin/testing/junit/ide/action/RunAllTestAction.java
#	plugins/plugin-testing-java/plugin-testing-junit/che-plugin-testing-junit-ide/src/main/java/org/eclipse/che/plugin/testing/junit/ide/action/RunClassTestAction.java
#	plugins/plugin-testing-java/plugin-testing-testng/che-plugin-testing-testng-ide/src/main/java/org/eclipse/che/plugin/testing/testng/ide/action/RunAllTestAction.java
#	plugins/plugin-testing-java/plugin-testing-testng/che-plugin-testing-testng-ide/src/main/java/org/eclipse/che/plugin/testing/testng/ide/action/RunClassTestAction.java
#	plugins/plugin-testing-java/plugin-testing-testng/che-plugin-testing-testng-ide/src/main/java/org/eclipse/che/plugin/testing/testng/ide/action/RunTestXMLAction.java
#	pom.xml
#	wsmaster/che-core-api-machine/pom.xml
2017-06-15 10:35:47 +03:00
..
che-sample-plugin-serverservice-ide Merge branch 'master' into spi 2017-06-15 10:35:47 +03:00
che-sample-plugin-serverservice-server RELEASE: Set next development version 2017-06-14 07:13:04 +00:00
README.md Remove unnecessary gwt.xml instructions (#5317) 2017-06-14 13:57:44 +03:00
pom.xml RELEASE: Set next development version 2017-06-14 07:13:04 +00:00

README.md

Description

This sample plugin show how to implement server service and how they are consumed from the client IDE.

Read the tutorial at: https://www.eclipse.org/che/docs/plugins/serverworkspace-access/index.html

How to test sample-serverservice plugin

The plugin-serverservice has both part, an IDE extension and a server extension. You have to introduce the extension as a dependency in /che/assembly/assembly-ide-war/pom.xml.

Add:

...
<dependency>
  <groupId>org.eclipse.che.sample</groupId>
  <artifactId>che-sample-plugin-serverservice-ide</artifactId>
</dependency>
...

You can insert the dependency anywhere in the list. After you have inserted it, run mvn sortpom:sort and maven will order the pom.xml for you.

The plugin-serverservice has a server side part. You have to introduce the extension as a dependency in /che/assembly/assembly-wsmaster-war/pom.xml.

Add:

...
<dependency>
  <groupId>org.eclipse.che.sample</groupId>
  <artifactId>che-sample-plugin-serverservice-server</artifactId>
</dependency>
...

You can insert the dependency anywhere in the list. After you have inserted it, run mvn sortpom:sort and maven will order the pom.xml for you.

3- Rebuild Eclipse Che

# Create a new Che server web app that includes your Che server extension
cd che/assembly/assembly-wsmaster-war
mvn clean install

# Build a new IDE.war
# This IDE web app will be bundled into the assembly
cd che/assembly/assembly-ide-war
mvn clean install

# Create a new Che assembly that includes all new server- and client-side extensions
cd assembly/assembly-main
mvn clean install

5- Run Eclipse Che

# Start Che using the CLI with your new assembly
# Replace <local-repo> with the path to your Che repository, to use local binaries in your local image
# Replace <version> with the actual version you are working on
docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock \
                    -v <local-path>:/data \
                    -v <local-repo>:/repo \
                       eclipse/che:<version> start --debug

Documentation resources