public MMetastoreDBProperties putProperties(String key, String value, String description,  byte[] content) {
    boolean success = false;
    try {
      if (openTransaction()) {
        //pm.currentTransaction().setOptimistic(false);
        // fetch first to determine new vs update
        MMetastoreDBProperties properties = doFetchProperties(key, null);
        final boolean newInstance;
        if (properties == null) {
          newInstance = true;
          properties = new MMetastoreDBProperties();
          properties.setPropertykey(key);
        } else {
          newInstance = false;
        }
        properties.setDescription(description);
        properties.setPropertyValue(value);
        properties.setPropertyContent(content);
        LOG.debug("Attempting to add property {} for the metastore db", key);
        properties.setDescription("Metastore property "
            + (newInstance ? "created" : "updated")
            + " " + LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss.SSS")));
        if (newInstance) {
          pm.makePersistent(properties);
        }
        success = commitTransaction();
        if (success) {
          LOG.info("Metastore property {} created successfully", key);
          return properties;
        }
      }
    } finally {
      rollbackAndCleanup(success, null);
    }
    return null;
  }
Called right before an action that would drop a storage descriptor.
This function makes the SD's reference to a CD null, and then deletes the CD
if it no longer is referenced in the table.
@param msd the storage descriptor to drop
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/ObjectStore.java