for (Resource service : services) {
ResourceComponent serviceComponent =
PluginContainer.getInstance().getInventoryManager().getResourceComponent(service);
if (serviceComponent instanceof MeasurementFacet) {
Set<MeasurementScheduleRequest> metricList = new HashSet<MeasurementScheduleRequest>();
metricList.add(new MeasurementScheduleRequest(1, "wwwSummaryInRequests", 1000, true,
DataType.MEASUREMENT));
metricList.add(new MeasurementScheduleRequest(2, "wwwRequestInRequests.GET", 1000, true,
DataType.MEASUREMENT));
MeasurementReport report = new MeasurementReport();
((MeasurementFacet) serviceComponent).getValues(report, metricList);
for (MeasurementData data : report.getNumericData()) {
System.out.println(data.getValue() + ":" + service.getName());