Handle demotion gate transport failures safely
This commit is contained in:
@@ -39,7 +39,7 @@ mc_pg_demote_database_shadow()
|
||||
|
||||
[ -n "${resource}" ] || return 0
|
||||
|
||||
response="$(
|
||||
if response="$(
|
||||
timeout --kill-after=1s 5s \
|
||||
python3 \
|
||||
"${MC_PROXY_CLIENT:-/usr/lib/ocf/resource.d/loxthelion/managed-container.d/proxy_client.py}" \
|
||||
@@ -48,8 +48,11 @@ mc_pg_demote_database_shadow()
|
||||
"demote.database" \
|
||||
10 \
|
||||
11
|
||||
)"
|
||||
rc=$?
|
||||
)"; then
|
||||
rc=0
|
||||
else
|
||||
rc=$?
|
||||
fi
|
||||
|
||||
if [ "${rc}" -ne 0 ]; then
|
||||
ocf_log warn \
|
||||
|
||||
Reference in New Issue
Block a user