4
4
5
5
set -euo pipefail
6
6
7
- # retry_rowcount <path> <expected> <label> <parquet_jar>
7
+ # retry_rowcount <path> <expected> <parquet_jar>
8
8
# path – shell glob pointing to a Parquet folder (wildcards allowed).
9
9
# The glob is passed verbatim to parquet-tools, which understands
10
10
# Hadoop-style wild-cards (e.g. "…/*/Patient/").
11
11
# expected – integer row count we expect to see.
12
- # label – short metric name for log messages.
13
12
# parquet_jar – full path to the parquet-tools JAR file.
14
13
#
15
14
# Prints the final count on stdout.
16
15
17
16
retry_rowcount () {
18
17
local parquet_glob=" $1 "
19
18
local expected=" $2 "
20
- local label=" $3 "
21
- local parquet_tools_jar=" $4 "
19
+ local parquet_tools_jar=" $3 "
22
20
23
21
# CI can override cadence through env vars
24
- local max_retries=" ${ROWCOUNT_MAX_RETRIES:- 12 } "
25
- local sleep_secs=" ${ROWCOUNT_SLEEP_SECS:- 5 } "
22
+ local max_retries=" ${ROWCOUNT_MAX_RETRIES:- 15 } "
23
+ local sleep_secs=" ${ROWCOUNT_SLEEP_SECS:- 20 } "
26
24
27
25
local retries=0
28
26
local raw_count=0
@@ -42,7 +40,7 @@ retry_rowcount() {
42
40
43
41
# ── 2. Normalise raw_count
44
42
if [[ -z " ${raw_count} " || ! " ${raw_count} " =~ ^[0-9]+$ ]]; then
45
- echo " E2E TEST ERROR: [${label } ] parquet-tools returned '${raw_count} ' " \
43
+ echo " E2E TEST ERROR: [${parquet_glob } ] parquet-tools returned '${raw_count} ' " \
46
44
" (treating as 0)" >&2
47
45
final_count=0
48
46
else
@@ -66,7 +64,7 @@ retry_rowcount() {
66
64
67
65
# ── 6. Sleep & retry
68
66
retries=$(( retries + 1 ))
69
- echo " E2E TEST: [${label } ] raw=${raw_count} , expected=${expected} — retry ${retries} /${max_retries} in ${sleep_secs} s" >&2
67
+ echo " E2E TEST: [${parquet_glob } ] raw=${raw_count} , expected=${expected} — retry ${retries} /${max_retries} in ${sleep_secs} s" >&2
70
68
sleep " ${sleep_secs} "
71
69
done
72
70
}
0 commit comments