-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ws.next walking skeleton #10123
Comments
@l0rd what is Che backend plugin? Is this a scenario where a backend plugin is a sidecar? If not, don't we want to target such a scenario? |
@eivantsov yes the scenario is about that. A che plugin that runs in a sidecar container and communicates with a theia plugin to provide the UI functionality (like a language server and its theia client). What I wanted to stress is that the user need to specify one plugin only ( |
@l0rd thanks. got it. SO, a feature, speaking in old fashioned ws.next terms :) For such a scenario, there's one important dependency - Theia LSP client being able to connect to LS over host:port. |
Theia clients should contact a Che service using the Plugin endpoint name. No port (port 80). For this first scenario it's ok to hardcode the endpoint name in the theia client. We should make it a parameter to pass to the theia client in future iterations. |
@l0rd not Che API (its clear that we have a plugin that provides such endpoints), but LS running in tcp mode. That would be the most interesting scenario - Che plugin bringing over Theia plugin + a sidecar. |
A couple of remarks and changes. Marketplace content
Where che-plugin.ymlversion: 0.0.1
type: Che Plugin
name: che-hello-world
id: che-java
title: Che Hello plugin
description: ...
icon: https://....
endpoints:
- name: "hello-ls"
public: true
targetPort: 8080
containers:
- name: che-hello
image: eclipse/che-hello:nightly
env:
- name: ENV1
value: VAL1
editor-commands:
- name: build
working-dir: "$(project)"
command: ["mvn", "clean", "install"]
volumes:
- mountPath: "/projects"
name: projects
ports:
- exposedPort: 8080
editors:
- name: org.eclipse.che.editor.theia
plugins: [theia-hello-world:1.0.0]
- name: org.eclipse.che.editor.jupyter
plugins: [jupyter-hello-client, jupyter-hello2-client] che-editor.ymlversion: 1.0.0
type: Che Editor
name: org.eclipse.che.editor.theia
id: theia-ide
plugins: theia-plugins
title: Theia for Che
Description: ...
Icon: https://....
endpoints:
- name: "ide"
public: true
targetPort: 8080
containers:
- name: theia-ide
image: eclipse/che-editor-theia:nightly
env:
- name: theia-plugins
value: file://plugins/
- name: ENV1
value: VAL1
editor-commands:
- name: reload-plugins
working-dir: "$(plugins)"
command: ["node", "reload"]
volumes:
- mountPath: "/plugins"
name: plugins
- mountPath: "/project"
name: project
ports:
- exposedPort: 8080 Notes
Usecase 1
Usecase 2
|
I agree that we should not use kubernetes as a common base and that there are might be ussies that prevent master from using init containers directly without additional operation. Apart from that copying binaries from marketplace to workspaces may lead to heavy load of workspace master and bad response time to API requests. The flow looks pretty complete. I can just suggest considering to include factories into it. Maybe as a second step. And I just figured out that Che factories feature doesn't have attributes. So, we can't use factories with workspace.next. Should we add those to factories? |
Making the workspace in charge of provisioning the plugins before the container is started allow to handle more efficiently
|
@skabashnyuk why in usecase1 you prefixed with "theia-plugin/" the plugin ?
is enough here what you said
|
@eivantsov yes let's support HTTP only for this walking skeleton @skabashnyuk great review thanks a lot of interesting points: Change proposals that I have integrated in the issue body
Change proposals that I don't think are needed for the skeletonImplementing a walking skeleton is about making the minimum to build something that works end to end. With that in mind, even if these are good ideas, I would avoid to include it the skeleton:
Proposals that need further discussion
@garagatyi ok to investigate using a docker image to copy the theia plugins in the plugins folder. That may be simpler than |
@l0rd ok |
Do you have resource consumption (e.g. memory) figures impact of multiple sidecar containers comparing to single container with multiple agents? Is it worth for example to have a dedicated container just for the IDE (Serve Static Resources)? Do you have target memory figure for typical developer? (don’t get me wrong - I totally understand the benefit of the multiple containers: decoupling, stability, LCM, etc.) |
IDE won't be a static hosting service. IDE always has some backend, e.g. API that provides access to source files. |
@tamirmenahem 2 processes in 2 distinct containers or in one container should consume the same amount of memory. It would have been a concern if we had to run more JVMs (one per containers). But that's not the case (IDE is run by nodejs, jdt.ls is run by the JVM, exec agent is go etc...). Anyway the implementation of this skeleton should provide rapidly a factual answer and confirm (or not) the initial assumptions. |
I created a general task of ChePlugin binaries delivering #10561 and moved all the corresponding subtasks from this epic to that issue. |
Sorry for asking pretty basic question. I am new to this world. What is the difference between che-plugin & theia-plugin? I read through this issue, but it isn't clear to me. Thanks, |
@rsankarprgs you're correct. A theia plug-in is a plug-in for the IDE/editor (that can run on theia nodejs side or inside browse web worker) A che plug-in is a super set of plug-ins.
|
Thanks. |
Added a note that Move preparing of RuntimeContext to the async phase of workspace start #8989 may not be delivered until 11 September |
Fix for che-service plug-in : ws-skeleton/che-service-plugin#2 |
I moved the task with QE tests to the Eclipse Con epic since during our meeting with Mario we decided that it is not blocking this epic |
@l0rd Looks like we can close this epic since all the tasks were completed. Do you mind if I close it? |
@garagatyi yep, the skeleton has been built ☠️ Congrats to all the engineers involved 🎉 🎉 |
Walking Skeleton Details
Goal: Integrate ws.next and theia plugin + introduce the plugin registry
User Story 1: As a Che developer I want to start a ws.next based workspace that is configured to load theia as the editor and an “hello world” frontend theia plugin (using an existing che stack from the dashboard and with the editor and plugins definition available in a remote plugin registry) so that I will be able to easily extend this model developing new theia plugins.
User Story 2: Same as Story 1 but instead of the “hello world” frontend theia plugin the workspace should be configured to load a backend Che plugin that includes a theia plugin part (frontend) so that I will be able to easily extend this model developing new che plugins.
Success Criteria The plugin registry is deployed on OSIO and rh-che is configured to use it. 2 new stacks (for Story1 and Story2) are available on rh-che and I can start a workspace based on both on OSIO.
What’s in the walking skeleton Support of 2 simple stories (not a feature complete IDE), 2 che stacks, works on Kubernetes, works on OSIO
What’s not in the walking skeleton A feature complete IDE, Self Hosting, Che Terminal, Java LS, Documentation, Performance tuning, UI components, ws.next Factories
Target 11 September
Architectural Details
Che Plugin Registry
Packaging and Runtime
The registry is an http server (apache, nginx or whatever fits better) packaged as a docker image (will be
eclipse/che-plugin-registry
now it'sgaragatyi/che-marketplace:os
). The docker image contains also the plugins metadata (for both Che plugins and Che editors). This list will be served statically by the apache server.The Dockerfile (that defines the registry Docker image) and the plugins metadata will be in a repository
eclipse/che-plugin-registry
. A CI will build automatically the Docker image after each PR is merged (it can be the Docker hub autobuild for example).For development purposes the registry can be started locally and in general anyone can start it's own registry in his infrastructure. For OpenShift.io we will run a Che plugin registry on DSAAS that will serve che.openshift.io.
Plugins (and Editor) Metadata
The plugins and editors metadata will be in some subfolders of the
plugins
folder of the git repository:The meta.yml file has the following format for a plugin
Note that both plugins and editors are under the
plugins
folderContributing (adding a new plugin to the registry)
A plugin author can contribute to the plugin registry with a PR. He will need to add a new folder matching the plugin id and version. The folder should contain a meta.yaml file:
The Che Plugin Packaging
Every Che plugin/editor should be packaged as a tarball + one or more Docker images.
A tarball contains the following files:
che-plugin.yaml
(mandatory): the plugin details like the plugin containers, endpoints and theia pluginsdependencies.yaml
(only if the plugin has dependencies): the details of the plugin required dependencies (typically a list of theia plugins)example.theia
(only example.theia is a plugin's dependency): a theia pluginThe docker image contains the backend services (e.g. a language server) or command line tooling (e.g. kubectl or oc)
An example of che-plugin.yaml:
An example of
dependency.yaml
:Notes:
Che Workspace Lifecycle
Configuration
The Che plugins and the Che editor of a workspace are defined as workspace attributes:
The format of the plugins name is
<id>:<version>
whereid
andversion
are defined in the pluginmeta.yaml
Start
The URL of the plugin registry should be a wsmaster property
Subtasks
OSIO team
IDE2 team
che-plugin.yaml
+dependency.yaml
and publish it in a repositoryPLATFORM team
The text was updated successfully, but these errors were encountered: