@Override
    public String updateForBlueprintExport(String propertyName,
                                           String value,
                                           Map<String, Map<String, String>> properties,
                                           ClusterTopology topology) {
      for (HostGroupInfo groupInfo : topology.getHostGroupInfo().values()) {
        Collection<String> hosts = groupInfo.getHostNames();
        for (String host : hosts) {
          value = value.replaceAll(host + "\\b", "%HOSTGROUP::" + groupInfo.getHostGroupName() + "%");
        }
      }

      return value;
    }
Update all host names included in the original property value with new host names which run the associated
component.

@param propertyName property name
@param origValue    original value of property
@param properties   all properties
@param topology     cluster topology
@return updated property value with old host names replaced by new host names
ambari-server/src/main/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessor.java