private static void addKeyValuePair(Configuration jobConf, String property, String keyName, String newKeyValue) {
    String existingValue = jobConf.get(property);

    if (StringUtils.isBlank(existingValue)) {
      jobConf.set(property, (keyName + EQUALS + newKeyValue));
      return;
    }
    String propertyValue = HiveStringUtils.insertValue(keyName, newKeyValue, existingValue);
    jobConf.set(property, propertyValue);
  }
Sets a "keyName=newKeyValue" pair to a jobConf to a given property.
If the property is empty, it simply inserts keyName=newKeyValue,
if it's already filled, it takes care of appending or replacing it in the currently present value.
The property in jobConf contains a value like: "key1=value1,key2=value2".
@param jobConf
@param property
@param keyName
@param newKeyValue
common/src/java/org/apache/hadoop/hive/conf/HiveConfUtil.java