public void addComponentMapping(String serviceName, String componentName) {
    if (serviceName == null){
      serviceName = "";
    }
    if (componentName == null) {
      componentName = "*";
    }
    serviceMapping.get(serviceName).add(componentName);
  }
Class that represents principal and it info(host, keytab path, service and component mapping).
ambari-server/src/main/java/org/apache/ambari/server/serveraction/kerberos/stageutils/ResolvedKerberosPrincipal.java