public Object removeProperty(String name) {
    if (!dirty) {
      final Map<String, Object> map = this.properties;
      synchronized (map) {
        if (!map.containsKey(name)) {
          return null;
        }
        // copy on write
        this.properties = new TreeMap<>(map);
        dirty = true;
      }
    }
    final Map<String, Object> map = this.properties;
    synchronized (map) {
      Object value;
      if ((value = map.remove(name)) != null) {
        digest = null;
      }
      return value;
    }
  }
Removes a property from this map.

@param name the property name
@return the value that was set or null
standalone-metastore/metastore-common/src/main/java/org/apache/hadoop/hive/metastore/properties/PropertyMap.java