@Override
  public AlterPartitionMessage buildAlterPartitionMessage(Table table, Partition before, Partition after,
                                                          Long writeId) {
    return new JSONAlterPartitionMessage(HCAT_SERVER_URL, HCAT_SERVICE_PRINCIPAL,
        before.getDbName(), before.getTableName(), table.getTableType(),
        MessageBuilder.getPartitionKeyValues(table,before), writeId, now());
  }
The JSON implementation of the MessageFactory. Constructs JSON implementations of
each message-type.
hcatalog/server-extensions/src/main/java/org/apache/hive/hcatalog/messaging/json/JSONMessageFactory.java