private static String[] getRrdNames(OnmsResource resource, String[] dsNames) { String[] rrds = new String[dsNames.length]; Map<String, RrdGraphAttribute> attributes = resource.getRrdGraphAttributes(); for (int i=0; i < dsNames.length; i++) { RrdGraphAttribute attribute = attributes.get(dsNames[i]); if (attribute == null) { throw new IllegalArgumentException("RRD attribute '" + dsNames[i] + "' is not available on resource '" + resource.getId() + "'. Available RRD attributes: " + StringUtils.collectionToDelimitedString(attributes.keySet(), ", ")); } rrds[i] = RrdFileConstants.escapeForGraphing(attribute.getRrdRelativePath()); } return rrds; }
private static String[] getRrdNames(OnmsResource resource, String[] dsNames) { String[] rrds = new String[dsNames.length]; Map<String, RrdGraphAttribute> attributes = resource.getRrdGraphAttributes(); for (int i=0; i < dsNames.length; i++) { RrdGraphAttribute attribute = attributes.get(dsNames[i]); if (attribute == null) { throw new IllegalArgumentException("RRD attribute '" + dsNames[i] + "' is not available on resource '" + resource.getId() + "'. Available RRD attributes: " + StringUtils.collectionToDelimitedString(attributes.keySet(), ", ")); } rrds[i] = RrdFileConstants.escapeForGraphing(attribute.getRrdRelativePath()); } return rrds; }
"--start=" + (startTimeInMillis / 1000), "--end=" + (endTimeInMillis / 1000), "DEF:ds1=" + RrdFileConstants.escapeForGraphing(rrdAttribute.getRrdRelativePath()) + ":" + attribute.getName() + ":" + rraConsolidationFunction, };