/**
  * Coprocessor Action.
  *
  * @param env MasterProcedureEnv
  * @param state the procedure state
  * @throws IOException
  * @throws InterruptedException
  */
 private void runCoprocessorAction(
     final MasterProcedureEnv env, final ModifyColumnFamilyState state)
     throws IOException, InterruptedException {
   final MasterCoprocessorHost cpHost = env.getMasterCoprocessorHost();
   if (cpHost != null) {
     switch (state) {
       case MODIFY_COLUMN_FAMILY_PRE_OPERATION:
         cpHost.preModifyColumnFamilyAction(tableName, cfDescriptor, user);
         break;
       case MODIFY_COLUMN_FAMILY_POST_OPERATION:
         cpHost.postCompletedModifyColumnFamilyAction(tableName, cfDescriptor, user);
         break;
       default:
         throw new UnsupportedOperationException(this + " unhandled state=" + state);
     }
   }
 }