@Override public void preAlterTable(Table table, EnvironmentContext context) throws MetaException {
    String alterOpType = context == null ? null : context.getProperties().get(ALTER_TABLE_OPERATION_TYPE);
    // alterOpType is null in case of stats update
    if (alterOpType != null && !ALLOWED_ALTER_TYPES.contains(alterOpType)) {
      throw new MetaException("ALTER TABLE can not be used for " + alterOpType + " to a non-native table ");
    }
    if (DruidKafkaUtils.isKafkaStreamingTable(table)) {
      updateKafkaIngestion(table);
    }
  }
This function checks the load status of Druid segments by polling druid coordinator.
@param segments List of druid segments to check for
druid-handler/src/java/org/apache/hadoop/hive/druid/DruidStorageHandler.java