Reviewed:  https://review.openstack.org/51258
Committed: 
http://github.com/openstack/nova/commit/49d60d1f1321c8c7860e021c5137551d87fac6cf
Submitter: Jenkins
Branch:    milestone-proposed

commit 49d60d1f1321c8c7860e021c5137551d87fac6cf
Author: Joe Cropper <jwcro...@us.ibm.com>
Date:   Thu Oct 10 16:38:33 2013 -0500

    Fix nova DB 215 migration script logic error
    
    This addresses a minor (albeit important) logic error in the migration 
script
    for https://review.openstack.org/#/c/46379/ - that script currently deletes
    compute node stats for active compute nodes.  This patch reverses that logic
    so it deletes the correct set of compute node stats.
    
    Also included is a migration test case to demonstrate the behavior.
    
    Change-Id: I77afcf443357d0767ac933d791a565289eabee9a
    Closes-Bug: #1238281
    (cherry picked from commit c3330931113ac2edf5961a653e5c2cfe459c13a0)


** Changed in: nova
       Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1238281

Title:
  Migration script deletes wrong compute node stats

Status in OpenStack Compute (Nova):
  Fix Released

Bug description:
  The nova DB migration script for 215 executes:

  result = conn.execute(
          'update compute_node_stats set deleted = id, '
          'deleted_at = current_timestamp where compute_node_id not in '
          '(select id from compute_nodes where deleted <> 0)')

  Need to remove the 'not' part so that we delete the right stats since
  the nested select finds all DELETED nodes.  The current SQL actually
  deletes all active compute nodes' stats.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1238281/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to     : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp

Reply via email to