Remove downgrades from migrations

According to cross project spec
I622f89fe63327d44f9b229d3bd9e76e15acbaa7a downgrade
migrations should be removed.

Change-Id: Iee38d8ba5e414e67033db35db52724d3f9f84fd7
changes/35/297635/1
Anton Arefiev 7 years ago
parent a12d1af680
commit a94486d809

@ -39,7 +39,7 @@ def add_command_parsers(subparsers):
parser = add_alembic_command(subparsers, name)
parser.set_defaults(func=do_alembic_command)
for name in ['downgrade', 'stamp', 'show', 'edit']:
for name in ['stamp', 'show', 'edit']:
parser = add_alembic_command(subparsers, name)
parser.set_defaults(func=with_revision)
parser.add_argument('--revision', nargs='?', required=True)

@ -30,7 +30,3 @@ ${imports if imports else ""}
def upgrade():
${upgrades if upgrades else "pass"}
def downgrade():
${downgrades if downgrades else "pass"}

@ -61,9 +61,3 @@ def upgrade():
mysql_ENGINE='InnoDB',
mysql_DEFAULT_CHARSET='UTF8'
)
def downgrade():
op.drop_table('nodes')
op.drop_table('attributes')
op.drop_table('options')

@ -62,9 +62,3 @@ def upgrade():
mysql_ENGINE='InnoDB',
mysql_DEFAULT_CHARSET='UTF8'
)
def downgrade():
op.drop_table('rules')
op.drop_table('rule_conditions')
op.drop_table('rule_actions')

@ -31,7 +31,3 @@ import sqlalchemy as sa
def upgrade():
op.add_column('rule_conditions', sa.Column('invert', sa.Boolean(),
nullable=True, default=False))
def downgrade():
op.drop_column('rule_conditions', 'invert')

@ -0,0 +1,5 @@
---
features:
- Database migrations downgrade was removed. More info about
database migration/rollback could be found here
http://docs.openstack.org/openstack-ops/content/ops_upgrades-roll-back.html
Loading…
Cancel
Save