Skip to content

Commit 4b1208e

Browse files
committed
replaced outdated examples with an up-to-date one
1 parent c89fee6 commit 4b1208e

File tree

16 files changed

+61
-348
lines changed

16 files changed

+61
-348
lines changed

examples/docker-unix/README.md

Lines changed: 0 additions & 3 deletions
This file was deleted.

examples/docker-unix/cardamon.unix.toml

Lines changed: 0 additions & 27 deletions
This file was deleted.

examples/docker-unix/db/docker-compose.yml

Lines changed: 0 additions & 6 deletions
This file was deleted.

examples/docker-unix/test/docker-compose.yml

Lines changed: 0 additions & 8 deletions
This file was deleted.

examples/hybrid/Dockerfile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
FROM ubuntu:latest
2+
3+
WORKDIR /app
4+
COPY rand-api /app/rand-api
5+
RUN chmod +x /app/rand-api
6+
7+
EXPOSE 4242
8+
CMD ["./rand-api"]
9+
# ENTRYPOINT ["tail", "-f", "/dev/null"]

examples/hybrid/cardamon.toml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# CPU
2+
# ########################################
3+
[cpu]
4+
name = "AMD Ryzen 7 PRO 6850U with Radeon Graphics"
5+
curve = [
6+
7.627190097500079,
7+
0.07551567953624883,
8+
20.45110313049153,
9+
-1.5261422759740344,
10+
]
11+
12+
# Processes
13+
# ########################################
14+
[[process]]
15+
name = "rand-api"
16+
up = "./rand-api"
17+
down = "kill {pid}"
18+
redirect.to = "file"
19+
process.type = "baremetal"
20+
21+
[[process]]
22+
name = "rand-api-docker"
23+
up = "docker run -d --name c1 -p 4244:4243 rand-api"
24+
down = "bash -c 'docker stop c1 && docker rm c1'"
25+
redirect.to = "file"
26+
process.type = "docker"
27+
process.containers = ["c1"]
28+
startup_grace = 8000
29+
30+
# Scenarios
31+
# ########################################
32+
[[scenario]]
33+
name = "stress"
34+
desc = "Calls each instance of rand-api 1500 times"
35+
command = "sh scenario.sh"
36+
iterations = 2
37+
processes = ["rand-api", "rand-api-docker"]
38+
39+
# Observations
40+
# ########################################
41+
[[observation]]
42+
name = "stress"
43+
scenarios = ["stress"]
44+
45+
[[observation]]
46+
name = "live_monitor"
47+
processes = ["test_proc1", "test_proc2"]

examples/hybrid/rand-api

1.69 MB
Binary file not shown.

examples/hybrid/scenario.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/sh
2+
for i in $(seq 1 1500); do
3+
curl localhost:4243/rand >/dev/null 2>&1
4+
curl localhost:4244/rand >/dev/null 2>&1
5+
done

examples/tod/Dockerfile

Lines changed: 0 additions & 14 deletions
This file was deleted.

examples/tod/cardamon.toml

Lines changed: 0 additions & 22 deletions
This file was deleted.

0 commit comments

Comments
 (0)