All Projects → eclipse-emfcloud → ecore-glsp

eclipse-emfcloud / ecore-glsp

Licence: other
ecore-glsp

Programming Languages

java
68154 projects - #9 most used programming language
typescript
32286 projects
CSS
56736 projects

ecore-glsp

Build Status

For more information, please visit the EMF.cloud Website. If you have questions, contact us on our discussions page and have a look at our communication and support options.

Ecore GLSP provides a web-based editor for Ecore Models (including Diagrams), integrated with Eclipse Theia. It contains two components: one GLSP language server (Server-side, written in Java), and one GLSP client extension to actually present the diagrams (Using Sprotty).

Ecore GLSP can display an existing Ecore model. The diagram layout will be persisted in an .enotation file next to the .ecore file. The diagram editor also supports creation of new elements (EClasses, EAttributes, EReferences...), as well as partial support for editing existing elements (Renaming, deleting...).

Ecore GLSP Example

Prerequisites

Java

You need Java 11 to build the ecore-glsp editor.

Getting started

Clone the ecore-glsp editor:

git clone https://github.com/eclipse-emfcloud/ecore-glsp.git

Build server and client with the following build-script. This script also copies the needed server artifacts to the client.

cd ecore-glsp
./build.sh

Run

  • Start the client as it is described in the client README.
  • The copied backend artifacts are automatically launched on startup.
  • If you want to start the backends manually:
    • Execute the Java main classes: org.eclipse.emfcloud.ecore.glsp.EcoreServerLauncher and/or org.eclipse.emfcloud.ecore.modelserver.EcoreModelServerLauncher
    • On the client run yarn start:debug or the launch config Start Browser Backend (expects running GLSP Server instance)

Building and deploying via Docker

The client repo contains a Dockerfile, that builds the entire client application. The image listens on 0.0.0.0:3000 for incoming requests from a browser.

For installing docker locally please consult docker's installation description for your OS.

Locally build backend

Make sure to only build the backend (and not the front-end). This is needed before building the docker image.

./build.sh -b

Building docker image

Build the docker image using the following command, where <imagename> and <tagname> are replaced with the values you wish to use.

cd client
docker build -t <imagename>:<tagname> .

For example: docker build -t ecore-glsp .

Running in docker

When the docker image is built, you can start the container using the following command (where again the <imagename> and <tagename> are replaced).

docker run -it -p 3000:3000 --rm <imagename>:<tagname>

For example: docker run -it -p 3000:3000 --rm ecore-glsp

After that you should be able to connect with your browser at http://localhost:3000.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].