'Run the expansion phase of a rolling upgrade procedure.'

def expand(self):

    engine = db_api.get_engine()
    if (engine.engine.name != 'mysql'):
        sys.exit(_('Rolling    upgrades    are    currently    supported    only    for    MySQL'))
    expand_head = alembic_migrations.get_alembic_branch_head(db_migration.EXPAND_BRANCH)
    if (not expand_head):
        sys.exit(_("Database    expansion    failed.    Couldn't    find    head    revision    of    expand    branch."))
    self.sync(version=expand_head)
    curr_heads = alembic_migrations.get_current_alembic_heads()
    if (expand_head not in curr_heads):
        sys.exit((_('Database    expansion    failed.    Database    expansion    should    have    brought    the    database    version    up    to    "%(e_rev)s"    revision.    But,    current    revisions    are:    %(curr_revs)s    ') % {'e_rev': expand_head, 'curr_revs': curr_heads}))
