Debian Codegraph @

stress/v2/iql/file.iql

raw
1 CREATE DATABASE thing
2
3 CREATE DATABASE thing2
4
5 SET Database [thing]
6
7 SET Precision [s]
8
9 GO INSERT mockCpu
10 cpu,
11 host=server-[float inc(0) 10000],loc=[us-west|us-east|eu-north]
12 value=[int inc(100) 0]
13 100000 10s
14
15 GO QUERY mockCpu
16 SELECT mean(value) FROM cpu WHERE host='server-1'
17 DO 10
18
19 WAIT
20
21 SET DATABASE [thing2]
22
23 GO INSERT devices
24 devices,
25 city=[str rand(8) 100],country=[str rand(8) 25],device_id=[str rand(10) 100]
26 lat=[float rand(90) 0],lng=[float rand(120) 0],temp=[float rand(40) 0]
27 100000 10s
28
29 GO INSERT devices2
30 devices2,
31 city=[str rand(8) 100],country=[str rand(8) 25],device_id=[str rand(10) 100]
32 lat=[float rand(90) 0],lng=[float rand(120) 0],temp=[float rand(40) 0]
33 100000 10s
34
35 GO QUERY fooName
36 SELECT count(temp) FROM devices WHERE temp > 30
37 DO 10
38
39 WAIT
40
41 DROP DATABASE thing
42
43 DROP DATABASE thing2
44
45 WAIT