Skip to content

Commit 8f3b41f

Browse files
committed
docs: separate MPS plugin from model-server docs
1 parent 055f804 commit 8f3b41f

File tree

3 files changed

+50
-26
lines changed

3 files changed

+50
-26
lines changed
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
= How-To run the light `model-server` in MPS as plugin
2+
:navtitle: mps-model-server-plugin
3+
4+
5+
You can run a *light version* of the `model-server` directly in MPS via the dedicated *MPS as Modelix Model Server Plugin*, which is published over at the https://plugins.jetbrains.com/plugin/22834-mps-as-modelix-model-server[JetBrains Marketplace^].
6+
It always supports the latest MPS versions.
7+
8+
NOTE: More information on the component in general can be found in the xref:core:reference/component-mps-model-server-plugin.adoc[corresponding component reference].
9+
10+
[IMPORTANT]
11+
====
12+
A light model-server does not provide the full features as an independent `model-server` instance will.
13+
More *advanced features* will not work with this light version (e.g. modelix specific repositories/branches, or the xref:howto/metrics.adoc[metrics]).
14+
15+
If you want the full capabilities of the `model-server`, check out xref:howto/usage-model-api-gen-gradle.adoc[how to start it standalone].
16+
====
17+
18+
19+
== How to Install the Plugin
20+
21+
In MPS navigate to File -> Settings -> Plugins (left) -> Marketplace (top) -> Search for "modelix model server" -> Press *Install* -> Press *Restart IDE*.
22+
23+
image::model-server-plugin-marketplace.png[Installing the MPS model-server plugin]
24+
25+
You can access the light `model-server` via the
26+
xref:reference/component-light-model-client.adoc[light-model-client].
27+
28+
29+
== How to Run the Plugin
30+
31+
Once you restart MPS, the light `model-server` will start automatically with MPS.
32+
There are no graphical user interfaces, but to verify you can check the MPS log for
33+
34+
[source,bash]
35+
--
36+
starting modelix server
37+
--
38+
39+
The `model-server` will run by default on port `48305`.
40+
You can check the health status over at http://127.0.0.1:48305/health[^].
41+
42+
If you want to find out how connect a client and send queries to the plugin, have a look at the xref:howto/modelql.adoc[ModelQL documentation] or the xref:core:reference/component-mps-model-server-plugin.adoc[component reference].

docs/global/modules/core/pages/howto/usage-model-server.adoc

Lines changed: 7 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33

44
NOTE: If you are interested in a more practical usage of what is presented here, check out the https://github.com/modelix/modelix.samples[samples project^]
55

6+
NOTE: To run a light version of the `model-sever`, check out xref:core:howto/mps-model-server-plugin.adoc[]
7+
68
== Backends: In Memory vs. Database
79

810
The `model-server` will by default require a database backend.
@@ -19,7 +21,7 @@ The following list gives an overview of the many ways to run a `model-server`:
1921

2022
=== 1. Docker
2123

22-
We publish a docker container of the `model-server` over on https://hub.docker.com/r/modelix/model-server/tags[docker hub].
24+
We publish a docker container of the `model-server` over on https://hub.docker.com/r/modelix/model-server/tags[Docker Hub^].
2325
To run the model-server container with the in memory backend, simply call the following.
2426
[source, shell]
2527
--
@@ -51,9 +53,7 @@ Run using `docker-compose` via:
5153
$ docker-compose up
5254
--
5355

54-
NOTE: For more integrated examples, have a look at the
55-
xref:samples:monitoring.adoc[model server]
56-
monitoring setup in the samples, which starts the `model-server` using `docker-compose`.
56+
NOTE: For more integrated examples, have a look at the xref:core:howto/metrics.adoc[metrics and monitoring] capabilities, which shows how to start the `model-server` using `docker-compose`.
5757

5858
For more complex setups, which require a database backend, you can use the following:
5959

@@ -192,29 +192,10 @@ To give arguments to the gradle run command, you have to add them via the `--arg
192192
====
193193

194194

195-
=== 5. MPS
196-
197-
You can run a *light version* of the `model-server` directly in MPS via the dedicated *MPS as Modelix Model Server Plugin*, which is published over at the https://plugins.jetbrains.com/plugin/22834-mps-as-modelix-model-server[JetBrains Marketplace].
198-
199-
200-
[IMPORTANT]
201-
====
202-
A light model-server does not provide the full features as an independent `model-server` instance will.
203-
More *advanced features* (e.g. xref:core:howto/modelql-writing.adoc[ModelQL], or the xref:core:howto/metrics.adoc[metrics]) and *advanced clients* (e.g. xref:core:howto/modelql.adoc[ModelQLClient]) will not work.
204-
====
205-
206-
In MPS navigate to File -> Settings -> Plugins (left) -> Marketplace (top) -> search for "modelix model server" -> press install.
207-
208-
image::model-server-plugin-marketplace.png[Installing the MPS model-server plugin]
209-
210-
You can access the light `model-server` via the
211-
xref:core:reference/component-light-model-client.adoc[light-model-client].
212-
213-
214-
=== 6. *In Process* (Kotlin)
195+
=== 5. *In Process* (Kotlin)
215196

216197
This rather advanced version allows you to run the `model-server` inside your own application.
217-
You can find an examples of this in these code fragments:
198+
We primarily use this approach for testing, but theoretically it could be applied elsewhere.
199+
You can find an examples of this in the following code fragment:
218200

219201
* https://github.com/modelix/modelix.core/blob/main/model-server/src/test/kotlin/org/modelix/model/server/ModelClientV2Test.kt#L48[ModelClientV2Test (modelix core tests)]
220-
* https://github.com/modelix/modelix.core/blob/main/mps-model-server-plugin/src/main/kotlin/org/modelix/model/server/mps/MPSModelServer.kt#L77C22-L77C38[`MPSModelServer.kt` (Implementation of the 'MPS as Modelix Model Server' plugin)]

docs/global/modules/core/pages/reference/component-mps-model-server-plugin.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
https://api.modelix.org/3.12.0/mps-model-server-plugin/index.html[API doc^] | https://github.com/modelix/modelix.core[Repository^] | Artifacts: https://artifacts.itemis.cloud/service/rest/repository/browse/maven-mps/org/modelix/mps/model-server-plugin/[Nexus^] https://github.com/modelix/modelix.core/packages/1916747[GitHub Packages^]
77
--
88

9+
NOTE: Install instructions can be found in the xref:core:howto/mps-model-server-plugin.adoc[corresponding How-To].
910

1011
== Health checks
1112

0 commit comments

Comments
 (0)