Skip to content
Snippets Groups Projects
Commit 69e86543 authored by David Georg Reichelt's avatar David Georg Reichelt
Browse files

Refactor OpenTelemetry: Use case instead of multiple ifs

parent a8098446
No related branches found
No related tags found
No related merge requests found
...@@ -42,32 +42,15 @@ function cleanup { ...@@ -42,32 +42,15 @@ function cleanup {
function executeBenchmark() { function executeBenchmark() {
for index in $MOOBENCH_CONFIGURATIONS for index in $MOOBENCH_CONFIGURATIONS
do do
if [ $index == 0 ] case $index in
then 0) runNoInstrumentation 0 ;;
runNoInstrumentation 0 1) runOpenTelemetryNoLogging 1 ;;
cleanup 2) runOpenTelemetryLogging 2 ;;
fi 3) runOpenTelemetryZipkin 3 ;;
4) runOpenTelemetryPrometheus 4 ;;
esac
if [ $index == 1 ] cleanup
then
runOpenTelemetryNoLogging 1
cleanup
fi
if [ $index == 2 ]
then
runOpenTelemetryLogging 2
cleanup
fi
if [ $index == 3 ]
then
runOpenTelemetryZipkin 3
cleanup
fi
if [ $index == 4 ]
then
runOpenTelemetryPrometheus 4
cleanup
fi
done done
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment