[feature/migrations] Stop the update process if we are approaching time limit

PHPBB3-9737