WordPress at Your Fingertips
function is not described


Controller::schedule_migration() public WC 1.0

Set up the background migration process.

{} It's a method of the class: Controller{}

No Hooks.


null. Nothing.


$Controller = new Controller();

Code of Controller::schedule_migration() WC 6.1.1

public function schedule_migration() {
	$logging_tables = new ActionScheduler_LoggerSchema();
	$store_tables   = new ActionScheduler_StoreSchema();

	 * In some unusual cases, the expected tables may not have been created. In such cases
	 * we do not schedule a migration as doing so will lead to fatal error conditions.
	 * In such cases the user will likely visit the Tools > Scheduled Actions screen to
	 * investigate, and will see appropriate messaging (this step also triggers an attempt
	 * to rebuild any missing tables).
	 * @see https://github.com/woocommerce/action-scheduler/issues/653
	if (
		|| $this->migration_scheduler->is_migration_scheduled()
		|| ! $store_tables->tables_exist()
		|| ! $logging_tables->tables_exist()
	) {