public static Map<String, String> getConfigurationParameters(Element confElem) {
    Map<String, String> paramsMap = new HashMap<String, String>();
    Node paramsNode = confElem.getElementsByTagName("params").item(0);
    if (paramsNode != null) {
      NodeList paramsList = paramsNode.getChildNodes();
      for (int j = 0; j < paramsList.getLength(); j++) {
        Node paramNode = paramsList.item(j);
        if (paramNode != null && !paramsMap.containsKey(paramNode.getNodeName())) {
          paramsMap.put(paramNode.getNodeName(), paramNode.getTextContent());
        }
      }
    }
    return paramsMap;
  }
Given a configuration element, extract the params map.

@param confElem the configuration element
@return the params map or an empty map if one can't be found
app/com/linkedin/drelephant/util/Utils.java