aboutsummaryrefslogtreecommitdiffstats
path: root/yardstick
diff options
context:
space:
mode:
authorAbhijit Sinha <abhijit.sinha@intel.com>2017-10-18 16:44:45 +0100
committerRoss Brattain <ross.b.brattain@intel.com>2017-10-19 16:01:56 +0000
commitc0b3d5a7abc6acd0282c063844471ed6aa02d36b (patch)
treea985b4d0e96d62d16652eee44cc8f219c8068862 /yardstick
parentb3ebb0526501cba14055e00ee16606f85f6212eb (diff)
BugFix: Negative dropped packets in Prox tests
Removed the abs function which can potentially mask negative dropped packets. Dropped packets in Prox workload VNF = max((tx_packets - rx_packets), 0) Change-Id: I510a351e899cdf9a1f366d632b9f0528b1d9dcce Signed-off-by: Abhijit Sinha <abhijit.sinha@intel.com> (cherry picked from commit a27278dacaa54ae60cd3bdfa6e6145643f76fa02)
Diffstat (limited to 'yardstick')
-rw-r--r--yardstick/network_services/vnf_generic/vnf/prox_vnf.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/yardstick/network_services/vnf_generic/vnf/prox_vnf.py b/yardstick/network_services/vnf_generic/vnf/prox_vnf.py
index 24712dd27..b7d295eee 100644
--- a/yardstick/network_services/vnf_generic/vnf/prox_vnf.py
+++ b/yardstick/network_services/vnf_generic/vnf/prox_vnf.py
@@ -89,9 +89,9 @@ class ProxApproxVnf(SampleVNF):
return {}
result = {
- "packets_in": tx_total,
- "packets_dropped": abs(rx_total - tx_total),
- "packets_fwd": rx_total,
+ "packets_in": rx_total,
+ "packets_dropped": max((tx_total - rx_total), 0),
+ "packets_fwd": tx_total,
# we share ProxResourceHelper with TG, but we want to collect
# collectd KPIs here and not TG KPIs, so use a different method name
"collect_stats": self.resource_helper.collect_collectd_kpi(),