mirror of
https://github.com/phpbb/phpbb.git
synced 2025-05-31 03:29:23 +02:00
[feature/migrations] Change migration data processing to run step by step
This commit is contained in:
parent
ce021710fb
commit
91a921a96b
@ -167,7 +167,7 @@ class phpbb_db_migrator
|
||||
}
|
||||
else
|
||||
{
|
||||
$migration->update_data();
|
||||
$this->process_data_step($migration);
|
||||
$state['migration_data_done'] = true;
|
||||
$state['migration_end_time'] = time();
|
||||
}
|
||||
@ -182,6 +182,28 @@ class phpbb_db_migrator
|
||||
return true;
|
||||
}
|
||||
|
||||
function process_data_step(&$migration)
|
||||
{
|
||||
$continue = false;
|
||||
$steps = $migration->update_data();
|
||||
|
||||
foreach ($steps as $step)
|
||||
{
|
||||
$continue = $this->run_step($step);
|
||||
if (!$continue)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return $continue;
|
||||
}
|
||||
|
||||
function run_step(&$step)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
function insert_migration($name, $state)
|
||||
{
|
||||
$migration_row = $state;
|
||||
|
Loading…
x
Reference in New Issue
Block a user