Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix db migration down task #586

Merged
merged 16 commits into from May 22, 2015
Merged

Fix db migration down task #586

merged 16 commits into from May 22, 2015

Conversation

hansode
Copy link
Contributor

@hansode hansode commented May 21, 2015

Problem

Some down tasks break db:down.

Steps to reproduce:

  1. Setup latest wakame-vdc environment.
  2. Setup seed data
  3. rake db:down
$ cd /opt/axsh/wakame-vdc/dcmgr
$ time /opt/axsh/wakame-vdc/ruby/bin/bundle exec rake db:down

TODO(not for this PR)

  • Still can't rollback data completely in 0014_migrate_localstore_to_volume.rb after applying this change.
  • Specify schema version.
    • Current db:down implementation rolls back to version=1.
    • rake db:migrate VERSION=xxx

hansode added 16 commits May 21, 2015 18:49
* Mysql2::Error: Unknown table 'network_vif_monitors'
* Mysql2::Error: Can't DROP 'vlan_leases_tag_id_index'; check that column/key exists
* Mysql2::Error: Can't DROP 'bridge'; check that column/key exists
* Mysql2::Error: Can't DROP 'bridge_type'; check that column/key exists
* Mysql2::Error: Unknown table 'backup_storages'
* Mysql2::Error: Can't DROP 'job_states_session_id_index'; check that column/key exists
* Mysql2::Error: Can't DROP 'command'; check that column/key exists

* rake aborted!
  wrong number of arguments (0 for 1..2)
  /opt/axsh/wakame-vdc/dcmgr/vendor/bundle/ruby/2.0.0/gems/sequel-3.47.0/lib/sequel/database/schema_generator.rb:371:in `add_index'
  /opt/axsh/wakame-vdc/dcmgr/config/db/migrations/0002_v1203.rb:534:in `block (3 levels) in <top (required)>'
@hansode hansode self-assigned this May 21, 2015
@axsh-bot
Copy link

15bb517 success - wakame-ci/rspec

@axsh-bot
Copy link

15bb517 success - wakame-ci/rpmbuild

@axsh-bot
Copy link

15bb517 success - wakame-ci/to-s3

@axsh-bot
Copy link

15bb517 success - wakame-ci/dummy.smoke

@axsh-bot
Copy link

15bb517 success - wakame-ci/kvm.smoke.allowed-failure

@axsh-bot
Copy link

15bb517 failure - wakame-ci/lxc.smoke.allowed-failure

@axsh-bot
Copy link

15bb517 success - wakame-ci/kvm.smoke

@axsh-bot
Copy link

15bb517 success - wakame-ci/vz.smoke

@Metallion
Copy link
Contributor

Looks good to me. +1

Metallion added a commit that referenced this pull request May 22, 2015
@Metallion Metallion merged commit ebbd03c into master May 22, 2015
@hansode hansode deleted the fix-db-migration-down-task branch May 22, 2015 06:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants