From 285e051d05ba4a7b59d0b8aa658237150906e5cb Mon Sep 17 00:00:00 2001 From: imarom Date: Sun, 29 May 2016 12:52:00 +0300 Subject: fix for bug trex-210: double barrier is required to make sure sync with the server --- .../trex_control_plane/stl/trex_stl_lib/trex_stl_async_client.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_async_client.py') diff --git a/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_async_client.py b/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_async_client.py index 731ddb10..745a7fc5 100644 --- a/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_async_client.py +++ b/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_async_client.py @@ -178,7 +178,13 @@ class CTRexAsyncClient(): self.connected = True - # sync all stats data as a baseline from the server + # first barrier - make sure async thread is up + rc = self.barrier() + if not rc: + self.disconnect() + return rc + + # second barrier - sync all stats data as a baseline from the server rc = self.barrier(baseline = True) if not rc: self.disconnect() -- cgit 1.2.3-korg