Skip to content

Commit 350c121

Browse files
committed
Detector workflows might query consul/apricot for QC without requesting WORKFLOW_PARAMETERS=QC
1 parent 5afbf95 commit 350c121

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

DATA/common/gen_topo_helper_functions.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ add_W() # Add binarry to workflow command USAGE: add_W [BINARY] [COMMAND_LINE_OP
262262
WORKFLOW+=$WFADD
263263
}
264264

265-
if [[ ${EPNSYNCMODE:-0} == 1 && "${WORKFLOW_PARAMETERS:-}" =~ (^|,)"QC"(,|$) ]]; then
265+
if [[ ${EPNSYNCMODE:-0} == 1 ]]; then
266266
if [[ "${GEN_TOPO_DEPLOYMENT_TYPE:-}" == "ALICE_STAGING" ]]; then
267267
GEN_TOPO_QC_CONSUL_SERVER=ali-staging.cern.ch
268268
else
@@ -277,7 +277,7 @@ add_QC_from_consul()
277277
if [[ ! -z ${GEN_TOPO_QC_JSON_FILE:-} ]]; then
278278
curl -s -o $GEN_TOPO_QC_JSON_FILE "http://${GEN_TOPO_QC_CONSUL_SERVER}:8500/v1/kv${1}?raw"
279279
if [[ $? != 0 ]]; then
280-
echo "Error fetching QC JSON $1"
280+
echo "Error fetching QC JSON $1 (1)" 1>&2
281281
exit 1
282282
fi
283283
QC_CONFIG_ARG="json://${GEN_TOPO_QC_JSON_FILE}"
@@ -297,7 +297,7 @@ add_QC_from_apricot()
297297
curl -s -o $GEN_TOPO_QC_JSON_FILE "${GEN_TOPO_QC_APRICOT_SERVER}/${1}?process=true"
298298
fi
299299
if [[ $? != 0 ]]; then
300-
echo "Error fetching QC JSON $1"
300+
echo "Error fetching QC JSON $1 (2)" 1>&2
301301
exit 1
302302
fi
303303
QC_CONFIG_ARG="json://${GEN_TOPO_QC_JSON_FILE}"

DATA/production/qc-workflow.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ add_QC_JSON() {
2424
TMP_FILENAME=$FETCHTMPDIR/$1.$RANDOM.$RANDOM.json
2525
curl -s -o $TMP_FILENAME "http://${GEN_TOPO_QC_CONSUL_SERVER}:8500/v1/kv/${2/consul:\/\//}?raw"
2626
if [[ $? != 0 ]]; then
27-
echo "Error fetching QC JSON $2" 1>&2
27+
echo "Error fetching QC JSON $2 (3)" 1>&2
2828
exit 1
2929
fi
3030
elif [[ ${2} =~ ^apricot://.* ]]; then
@@ -35,9 +35,9 @@ add_QC_JSON() {
3535
else
3636
curl -s -o $TMP_FILENAME "${GEN_TOPO_QC_APRICOT_SERVER}/${2/apricot:\/\/o2\//}?run_type=${RUNTYPE:-}\&beam_type=${BEAMTYPE:-}\&process=true"
3737
fi
38-
38+
3939
if [[ $? != 0 ]]; then
40-
echo "Error fetching QC JSON $2" 1>&2
40+
echo "Error fetching QC JSON $2 (4)" 1>&2
4141
exit 1
4242
fi
4343
else
@@ -198,7 +198,7 @@ elif [[ -z ${QC_JSON_FROM_OUTSIDE:-} ]]; then
198198
else
199199
QC_JSON_ZDC=$O2DPG_ROOT/DATA/production/qc-async/zdc.json
200200
fi
201-
fi
201+
fi
202202
if [[ -z "${QC_JSON_EMC:-}" ]]; then
203203
if [[ "$BEAMTYPE" == "PbPb" ]]; then
204204
QC_JSON_EMC=$O2DPG_ROOT/DATA/production/qc-async/emc_PbPb.json
@@ -272,7 +272,7 @@ elif [[ -z ${QC_JSON_FROM_OUTSIDE:-} ]]; then
272272
if [[ $i == "PRIMVTX" ]] && ! has_detector_reco ITS; then continue; fi
273273
if [[ $i == "ITSTPC" ]] && ! has_detectors_reco ITS TPC; then continue; fi
274274
add_QC_JSON GLO_$i ${!DET_JSON_FILE}
275-
275+
276276
if [[ $i == "ITSTPC" ]]; then
277277
LOCAL_FILENAME=${JSON_FILES//*\ /}
278278
# replace the input sources depending on the detector compostition and matching detectors

0 commit comments

Comments
 (0)