[COMMIT osv-apps master] Add graalvm netty plot example to demonstrate more complex example using isolates

1 view
Skip to first unread message

Commit Bot

unread,
Jul 8, 2019, 11:18:01 PM7/8/19
to osv...@googlegroups.com, Waldemar Kozaczuk
From: Waldemar Kozaczuk <jwkoz...@gmail.com>
Committer: Waldemar Kozaczuk <jwkoz...@gmail.com>
Branch: master

Add graalvm netty plot example to demonstrate more complex example using
isolates

Signed-off-by: Waldemar Kozaczuk <jwkoz...@gmail.com>

---
diff --git a/graalvm-netty-plot/Makefile b/graalvm-netty-plot/Makefile
--- a/graalvm-netty-plot/Makefile
+++ b/graalvm-netty-plot/Makefile
@@ -0,0 +1,21 @@
+module: netty-plot
+
+GRAAL_VERSION=1.0.0-rc15
+
+netty-plot:
upstream/graalvm-demos/native-netty-plot/target/netty-plot-0.1-jar-with-dependencies.jar
upstream/graalvm-ce-$(GRAAL_VERSION)
+ upstream/graalvm-ce-$(GRAAL_VERSION)/bin/native-image --no-server
-Djava.net.preferIPv4Stack=true -jar
upstream/graalvm-demos/native-netty-plot/target/netty-plot-0.1-jar-with-dependencies.jar
+
+upstream/graalvm-demos/native-netty-plot/target/netty-plot-0.1-jar-with-dependencies.jar:
upstream/graalvm-ce-$(GRAAL_VERSION)
upstream/graalvm-demos/.git
+ cd upstream/graalvm-demos/native-netty-plot && mvn package
+
+upstream/graalvm-demos/.git:
+ mkdir -p upstream
+ cd upstream && git clone --depth 1
https://github.com/graalvm/graalvm-demos.git
+
+upstream/graalvm-ce-$(GRAAL_VERSION):
+ mkdir -p upstream
+ wget -c -O upstream//graalvm-ce-$(GRAAL_VERSION)-linux-amd64.tar.gz
https://github.com/oracle/graal/releases/download/vm-$(GRAAL_VERSION)/graalvm-ce-$(GRAAL_VERSION)-linux-amd64.tar.gz
+ cd upstream && tar xf graalvm-ce-$(GRAAL_VERSION)-linux-amd64.tar.gz
+
+clean:
+ rm -rf netty-plot upstream
diff --git a/graalvm-netty-plot/README.md b/graalvm-netty-plot/README.md
--- a/graalvm-netty-plot/README.md
+++ b/graalvm-netty-plot/README.md
@@ -0,0 +1,2 @@
+This demonstrates running GraalVM [native-netty-plot
app](https://github.com/graalvm/graalvm-demos/tree/master/native-netty-plot)
using isolates on OSv. For more information about the isolates please read
+[this
article](https://medium.com/graalvm/isolates-and-compressed-references-more-flexible-and-efficient-memory-management-for-graalvm-a044cc50b67e).
diff --git a/graalvm-netty-plot/module.py b/graalvm-netty-plot/module.py
--- a/graalvm-netty-plot/module.py
+++ b/graalvm-netty-plot/module.py
@@ -0,0 +1,3 @@
+from osv.modules import api
+
+default = api.run("/netty-plot")
diff --git a/graalvm-netty-plot/usr.manifest
b/graalvm-netty-plot/usr.manifest
--- a/graalvm-netty-plot/usr.manifest
+++ b/graalvm-netty-plot/usr.manifest
@@ -0,0 +1 @@
+/netty-plot: ${MODULE_DIR}/netty-plot
Reply all
Reply to author
Forward
0 new messages