diff options
author | Deepak S <deepak.s@linux.intel.com> | 2017-12-19 05:34:56 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2017-12-19 05:34:56 +0000 |
commit | 25ffc7091ffe7069e6b4aeed9a5a69aa034c58f9 (patch) | |
tree | b6e484c20b5575a292a1012000b33d45651dd359 /VNFs/DPPD-PROX/helper-scripts/openstackrapid/prox_ctrl.py | |
parent | 6401ebd2b472a2402b640f4e8c773cc3d097093f (diff) | |
parent | c10781eecde9452a477d7c9fa1f1fc0c63df559e (diff) |
Merge "Adding Security gateway testing"
Diffstat (limited to 'VNFs/DPPD-PROX/helper-scripts/openstackrapid/prox_ctrl.py')
-rw-r--r-- | VNFs/DPPD-PROX/helper-scripts/openstackrapid/prox_ctrl.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/VNFs/DPPD-PROX/helper-scripts/openstackrapid/prox_ctrl.py b/VNFs/DPPD-PROX/helper-scripts/openstackrapid/prox_ctrl.py index 7438d4d6..daa96a50 100644 --- a/VNFs/DPPD-PROX/helper-scripts/openstackrapid/prox_ctrl.py +++ b/VNFs/DPPD-PROX/helper-scripts/openstackrapid/prox_ctrl.py @@ -183,6 +183,16 @@ class prox_sock(object): def reset_stats(self): self._send('reset stats') + def lat_stats(self, cores, task=0): + min_lat = max_lat = avg_lat = 0 + self._send('lat stats %s %s' % (','.join(map(str, cores)), task)) + for core in cores: + stats = self._recv().split(',') + min_lat += int(stats[0]) + max_lat += int(stats[1]) + avg_lat += int(stats[2]) + return min_lat, max_lat, avg_lat + def core_stats(self, cores, task=0): rx = tx = drop = tsc = hz = 0 self._send('core stats %s %s' % (','.join(map(str, cores)), task)) |