@Override
  public void onAlterTable(AlterTableEvent tableEvent) throws MetaException {
    Table before = tableEvent.getOldTable();
    Table after = tableEvent.getNewTable();
    AlterTableMessage msg = MessageBuilder.getInstance()
        .buildAlterTableMessage(before, after, tableEvent.getIsTruncateOp(),
            tableEvent.getWriteId());
    NotificationEvent event =
        new NotificationEvent(0, now(), EventType.ALTER_TABLE.toString(),
            msgEncoder.getSerializer().serialize(msg)
        );
    event.setCatName(after.isSetCatName() ? after.getCatName() : getDefaultCatalog(conf));
    event.setDbName(after.getDbName());
    event.setTableName(after.getTableName());
    process(event, tableEvent);
  }
@param tableEvent alter table event
@throws MetaException
hcatalog/server-extensions/src/main/java/org/apache/hive/hcatalog/listener/DbNotificationListener.java