private static Map<Resource.InternalType, Map<String, Map<String, PropertyInfo>>> readPropertyProviderIds(String filename) {
    ObjectMapper mapper = new ObjectMapper();

    try {
      Map<Resource.InternalType, Map<String, Map<String, Metric>>> resourceMetricMap =
          mapper.readValue(ClassLoader.getSystemResourceAsStream(filename),
              new TypeReference<Map<Resource.InternalType, Map<String, Map<String, Metric>>>>() {});

      Map<Resource.InternalType, Map<String, Map<String, PropertyInfo>>> resourceMetrics =
        new HashMap<>();

      for (Map.Entry<Resource.InternalType, Map<String, Map<String, Metric>>> resourceEntry : resourceMetricMap.entrySet()) {
        Map<String, Map<String, PropertyInfo>> componentMetrics = new HashMap<>();

        for (Map.Entry<String, Map<String, Metric>> componentEntry : resourceEntry.getValue().entrySet()) {
          Map<String, PropertyInfo> metrics = new HashMap<>();

          for (Map.Entry<String, Metric> metricEntry : componentEntry.getValue().entrySet()) {
            String property = metricEntry.getKey();
            Metric metric   = metricEntry.getValue();
            PropertyInfo propertyInfo = new PropertyInfo(metric.getMetric(),
              metric.isTemporal(), metric.isPointInTime());
            propertyInfo.setAmsId(metric.getAmsId());
            propertyInfo.setAmsHostMetric(metric.isAmsHostMetric());
            propertyInfo.setUnit(metric.getUnit());
            metrics.put(property, propertyInfo);
          }
          componentMetrics.put(componentEntry.getKey(), metrics);
        }
        if (REPORT_METRIC_RESOURCES.contains(resourceEntry.getKey())) {
          updateMetricsWithAggregateFunctionSupport(componentMetrics);
        }
        resourceMetrics.put(resourceEntry.getKey(), componentMetrics);
      }
      return resourceMetrics;
    } catch (IOException e) {
      throw new IllegalStateException("Can't read properties file " + filename, e);
    }
  }
Factory method to create an update request from the given map of properties.
The properties values in the given map are used to update the resource.

@param properties             resource properties associated with the request; may be null
@param requestInfoProperties  request specific properties; may be null
ambari-server/src/main/java/org/apache/ambari/server/controller/utilities/PropertyHelper.java