This giant patch makes some much needed improvements to the code base. * The engine has been rewritten and lives within engine/graph/ * All of the common interfaces and code now live in engine/ * All of the resources are in one package called engine/resources/ * The Res API can use different "traits" from engine/traits/ * The Res API has been simplified to hide many of the old internals * The Watch & Process loops were previously inverted, but is now fixed * The likelihood of package cycles has been reduced drastically * And much, much more... Unfortunately, some code had to be temporarily removed. The remote code had to be taken out, as did the prometheus code. We hope to have these back in new forms as soon as possible.
25 lines
864 B
Bash
Executable File
25 lines
864 B
Bash
Executable File
#!/bin/bash -e
|
|
|
|
exit 0 # XXX: temporarily disabled until prometheus is added back post refactor
|
|
|
|
# run a graph, with prometheus support
|
|
$timeout --kill-after=60s 55s "$MGMT" run --tmp-prefix --no-pgp --prometheus --yaml prometheus-3.yaml &
|
|
pid=$!
|
|
sleep 10s # let it converge
|
|
|
|
# For test debugging purpose
|
|
curl 127.0.0.1:9233/metrics
|
|
|
|
# Three CheckApply for a File ; with events
|
|
curl 127.0.0.1:9233/metrics | grep '^mgmt_checkapply_total{apply="true",errorful="false",eventful="true",kind="file"} 3$'
|
|
|
|
# One CheckApply for a File ; in noop mode.
|
|
curl 127.0.0.1:9233/metrics | grep '^mgmt_checkapply_total{apply="false",errorful="false",eventful="true",kind="file"} 1$'
|
|
|
|
# Check mgmt_graph_start_time_seconds
|
|
curl 127.0.0.1:9233/metrics | grep "^mgmt_graph_start_time_seconds [1-9]\+"
|
|
|
|
killall -SIGINT mgmt # send ^C to exit mgmt
|
|
wait $pid # get exit status
|
|
exit $?
|