public ReplicationTask create(HCatClient client, HCatNotificationEvent event){
    // TODO : Java 1.7+ support using String with switches, but IDEs don't all seem to know that.
    // If casing is fine for now. But we should eventually remove this. Also, I didn't want to
    // create another enum just for this.
    if (event.getEventType().equals(HCatConstants.HCAT_CREATE_DATABASE_EVENT)) {
      return new CreateDatabaseReplicationTask(event);
    } else if (event.getEventType().equals(HCatConstants.HCAT_DROP_DATABASE_EVENT)) {
      return new DropDatabaseReplicationTask(event);
    } else if (event.getEventType().equals(HCatConstants.HCAT_CREATE_TABLE_EVENT)) {
      return new CreateTableReplicationTask(event);
    } else if (event.getEventType().equals(HCatConstants.HCAT_DROP_TABLE_EVENT)) {
      return new DropTableReplicationTask(event);
    } else if (event.getEventType().equals(HCatConstants.HCAT_ADD_PARTITION_EVENT)) {
      return new AddPartitionReplicationTask(event);
    } else if (event.getEventType().equals(HCatConstants.HCAT_DROP_PARTITION_EVENT)) {
      return new DropPartitionReplicationTask(event);
    } else if (event.getEventType().equals(HCatConstants.HCAT_ALTER_TABLE_EVENT)) {
      return new AlterTableReplicationTask(event);
    } else if (event.getEventType().equals(HCatConstants.HCAT_ALTER_PARTITION_EVENT)) {
      return new AlterPartitionReplicationTask(event);
    } else if (event.getEventType().equals(HCatConstants.HCAT_INSERT_EVENT)) {
      return new InsertReplicationTask(event);
    } else {
      return new ErroredReplicationTask(event, new IllegalStateException(
          "Unrecognized Event type, no replication task available"));
    }
  }
EXIMReplicationTaskFactory is an export-import based ReplicationTask.Factory.

It's primary mode of enabling replication is by translating each event it gets
from the notification subsystem into hive commands that essentially export data
to be copied over and imported on the other end.

The Commands that Tasks return here are expected to be hive commands.
hcatalog/webhcat/java-client/src/main/java/org/apache/hive/hcatalog/api/repl/exim/EximReplicationTaskFactory.java