Reduce Resource Consumption 98/7698/6
authorbeierl <mbeierl@vmware.com>
Mon, 24 Jun 2019 19:51:33 +0000 (15:51 -0400)
committerbeierl <mbeierl@vmware.com>
Fri, 28 Jun 2019 19:39:20 +0000 (15:39 -0400)
commit730dfd82ef49e2dc1f6d54bb8a1d5e877d4d50b2
treedeb375ba4a1b6d81cfee4fa71e762c206de7e907
parent7f8f893631706371a5e073a57b23866cfae712cb
Reduce Resource Consumption

The vmware vnf collector requests a time series of data from
vROPS and then parses the whole block in order to retrieve the
most recent data element.  The time frame for the request
should be limited to a sane value, such as 1 hour.

The look ups for items that do not change should be outside
of the loop for looking up the metrics.

Add more metrics to list of supported metrics.

Improve error handling.

BUG 784

Change-Id: Ie3cef457eaf657c18ba682e3c5d3abf40a759e69
Signed-off-by: beierl <mbeierl@vmware.com>
osm_mon/collector/vnf_collectors/vmware.py
osm_mon/tests/unit/collector/vnf_collectors/vmware/__init__.py [new file with mode: 0644]
osm_mon/tests/unit/collector/vnf_collectors/vmware/mock_vcd.py [new file with mode: 0644]
osm_mon/tests/unit/collector/vnf_collectors/vmware/osm_mocks/VNFD.json [new file with mode: 0644]
osm_mon/tests/unit/collector/vnf_collectors/vmware/osm_mocks/VNFR.json [new file with mode: 0644]
osm_mon/tests/unit/collector/vnf_collectors/vmware/test_vcd_collector.py [new file with mode: 0644]
osm_mon/tests/unit/collector/vnf_collectors/vmware/vcd_mocks/OK.json [new file with mode: 0644]
osm_mon/tests/unit/collector/vnf_collectors/vmware/vcd_mocks/vrops_multi.json [new file with mode: 0644]
test-requirements.txt
tox.ini