Skip to content

Commit 8dc4aa8

Browse files
committed
refactor: (GH-apache#85) Changes in benchmark after review
Signed-off-by: Saurabh Kumar Singh <[email protected]>
1 parent f6bdce6 commit 8dc4aa8

File tree

3 files changed

+9
-20
lines changed

3 files changed

+9
-20
lines changed

.github/workflows/benchmark.yml

+6-8
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,21 @@ on:
2121
branches: [ main ]
2222
pull_request:
2323
branches: [ main ]
24+
paths:
25+
- ".github/workflows/benchmark.yml"
2426
workflow_dispatch:
2527

28+
permissions:
29+
contents: read
30+
2631
jobs:
2732
benchmark:
2833
runs-on: ubuntu-latest
2934
container: debian:12
3035

3136
strategy:
3237
matrix:
33-
go: ['1.21']
38+
go: ['1.22.7']
3439
arch: ['amd64']
3540

3641
steps:
@@ -47,12 +52,6 @@ jobs:
4752
apt-get install -y build-essential git python3-pip
4853
4954
- name: Install Go ${{ matrix.go }} for Benchmarks
50-
if: >-
51-
success() &&
52-
matrix.arch == 'amd64' &&
53-
github.event_name == 'push' &&
54-
github.repository == 'apache/arrow-go' &&
55-
github.ref_name == 'main'
5655
uses: actions/setup-go@v5
5756
with:
5857
go-version: ${{ matrix.go }}
@@ -62,7 +61,6 @@ jobs:
6261
- name: Run Benchmarks
6362
if: >-
6463
success() &&
65-
matrix.arch == 'amd64' &&
6664
github.event_name == 'push' &&
6765
github.repository == 'apache/arrow-go' &&
6866
github.ref_name == 'main'

ci/scripts/bench.sh

+1-11
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,6 @@
2323

2424
set -ex
2525

26-
# simplistic semver comparison
27-
verlte() {
28-
[ "$1" = "`echo -e "$1\n$2" | sort -V | head -n1`" ]
29-
}
30-
verlt() {
31-
[ "$1" = "$2" ] && return 1 || verlte $1 $2
32-
}
33-
34-
ver=`go env GOVERSION`
35-
3626
source_dir=${1}
3727

3828
export PARQUET_TEST_DATA=${1}/cpp/submodules/parquet-testing/data
@@ -51,4 +41,4 @@ if [[ "$2" = "-json" ]]; then
5141
cat ${source_dir}/bench_*.dat | gobenchdata --json bench_stats.json
5242
fi
5343

54-
rm ${source_dir}/bench_*.dat
44+
rm ${source_dir}/bench_*.dat

ci/scripts/bench_adapt.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -124,4 +124,5 @@ def _transform_results(self) -> List[BenchmarkResult]:
124124

125125
if __name__ == "__main__":
126126
go_adapter = GoAdapter(result_fields_override={"info": {}})
127-
go_adapter()
127+
go_adapter()
128+

0 commit comments

Comments
 (0)