diff --git a/.github/scripts/sql-correctness/get-doltgres-correctness-job-json.sh b/.github/scripts/sql-correctness/get-doltgres-correctness-job-json.sh index 8d57da314c..fc136c1234 100755 --- a/.github/scripts/sql-correctness/get-doltgres-correctness-job-json.sh +++ b/.github/scripts/sql-correctness/get-doltgres-correctness-job-json.sh @@ -76,10 +76,9 @@ echo ' ], "args": [ "--schema=/correctness.sql", - "--concurrent", "--output='$format'", "--version='$version'", - "--timeout=600", + "--doltgres", '"$nomsBinFormat"' '"$issueNumber"' '"$regressComp"' diff --git a/.github/scripts/update-perf.sh b/.github/scripts/update-perf.sh new file mode 100755 index 0000000000..1c0ea7c3cb --- /dev/null +++ b/.github/scripts/update-perf.sh @@ -0,0 +1,84 @@ +#!/bin/bash + +set -ex +set -o pipefail + +root="`dirname \"$0\"`" +dir="`realpath \"$root\"`" +doltgres_root="`realpath \"$dir/../../\"`" + +version="" +sed_cmd_i="" +start_marker="" +end_marker="" + +dest_file="$doltgres_root/README.md" +os_type="darwin" + +start_template='' +end_template='' + +if [ "$#" -ne 3 ]; then + echo "Must supply version and type, eg update-perf.sh 'v0.39.0' 'latency|correctness' '/path/to/file'" + exit 1; +fi + +version="$1" +type="$2" +new_table="$3" + +if [[ "$OSTYPE" == "linux-gnu"* ]]; then + os_type="linux" +fi + + +if [ "$type" == "latency" ] +then + # update the version + if [ "$os_type" == "linux" ] + then + sed -i 's/Here are the benchmarks for DoltgreSQL version `'".*"'`/Here are the benchmarks for DoltgreSQL version `'"$version"'`/' "$dest_file" + else + sed -i '' "s/Here are the benchmarks for DoltgreSQL version \\\`.*\\\`/Here are the benchmarks for DoltgreSQL version \\\`$version\\\`/" "$dest_file" + fi + + start_marker=$(printf "$start_template" "LATENCY") + end_marker=$(printf "$end_template" "LATENCY") + +else + # update the version + if [ "$os_type" == "linux" ] + then + sed -i 's/Here are DoltgreSQL'"'"'s sqllogictest results for version `'".*"'`./Here are DoltgreSQL'"'"'s sqllogictest results for version `'"$version"'`./' "$dest_file" + else + sed -i '' 's/Here are DoltgreSQL'"'"'s sqllogictest results for version `'".*"'`./Here are DoltgreSQL'"'"'s sqllogictest results for version `'"$version"'`./' "$dest_file" + fi + + start_marker=$(printf "$start_template" "CORRECTNESS") + end_marker=$(printf "$end_template" "CORRECTNESS") +fi + +# store in variable +updated=$(cat "$new_table") +updated_with_markers=$(printf "$start_marker\n$updated\n$end_marker\n") + +echo "$updated_with_markers" > "$new_table" + +if [ "$type" == "latency" ] +then + if [ "$os_type" == "linux" ] + then + sed -e '/