From b164a74884becef281b57ef93428bb740e3e342e Mon Sep 17 00:00:00 2001 From: Pranith Kumar K Date: Tue, 4 Feb 2020 18:42:33 +0530 Subject: cluster/afr: Fixes for halo Current implementation assumes that ping-event will come after connect event but that may not be the case in the cases where after socket connection fds need to be re-opened which would consume more time. So handle any order of the ping/child-up events. fixes: bz#1800583 Change-Id: I6bcdc0caa503bdc039ef2b4739fbf4afae121f05 Signed-off-by: Pranith Kumar K --- tests/afr.rc | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'tests/afr.rc') diff --git a/tests/afr.rc b/tests/afr.rc index 35f352df78f..5fc7fa1898d 100644 --- a/tests/afr.rc +++ b/tests/afr.rc @@ -105,3 +105,13 @@ function get_quorum_type() local repl_id="$3" cat $m/.meta/graphs/active/$v-replicate-$repl_id/private|grep quorum-type|awk '{print $3}' } + +function afr_private_key_value() +{ + local v=$1 + local m=$2 + local replica_id=$3 + local key=$4 +#xargs at the end will strip leading spaces + grep -E "^${key} = " $m/.meta/graphs/active/${v}-replicate-${replica_id}/private | cut -f2 -d'=' | xargs +} -- cgit