Adding column and performing schema changes

Learn how to add a column to replicated Kudu tables or perform other schema modifications, such as dropping or renaming columns, by using a coordinated manual process.

This topic provides instructions for adding a column to replicated Kudu tables and performing schema modifications.

  1. Follow the Kudu replication Pre-stop checklist Completing the replication pre-stop checklist to drain the pipeline and stop the replication job by using a savepoint.
  2. Add the new column to the source Kudu table by running the following command:
    kudu table add_column <source-master-addresses> my_table new_column INT32 \
      --default 0
  3. Add the same column with the same definition to the sink Kudu table by running the following command:
    kudu table add_column <sink-master-addresses> my_table new_column INT32 \
      --default 0
  4. Restart the replication job from the savepoint. For more information, see Restarting the replication job and finding the job ID.