diff --git a/bench-native-optimized.sh b/bench-native-optimized.sh new file mode 100755 index 0000000..5eb12c6 --- /dev/null +++ b/bench-native-optimized.sh @@ -0,0 +1,24 @@ +set -e + +function print() { + printf "\033[1;35m$1\033[0m\n" +} + +print "Starting the native app 🚀" + +./target/demo-optimized -Xmx512m & +export PID=$! +psrecord $PID --plot "$(date +%s)-graalvm-native.png" --max-cpu 2200 --max-memory 900 --include-children & + +sleep 2 +print "Done waiting for startup..." + +print "Executing warmup load" +hey -n=250000 -c=8 http://localhost:8080/hello + +print "Executing benchmark load" +hey -n=250000 -c=8 http://localhost:8080/hello + +print "Native run done!🎉" +kill $PID +sleep 1 \ No newline at end of file diff --git a/bench-native.sh b/bench-native.sh index 5eb12c6..ac40bf6 100755 --- a/bench-native.sh +++ b/bench-native.sh @@ -6,7 +6,7 @@ function print() { print "Starting the native app 🚀" -./target/demo-optimized -Xmx512m & +./target/demo -Xmx512m & export PID=$! psrecord $PID --plot "$(date +%s)-graalvm-native.png" --max-cpu 2200 --max-memory 900 --include-children &