)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":7461,"name":"Paul Murray","email":"pmurray@hpe.com","username":"ptm"},"change_message_id":"276b7edf59a80b8a1c031fa257a0adb1318d0de6","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"during force_live_migration operation there are 2"},{"line_number":10,"context_line":"check of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc requst to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as there"},{"line_number":13,"context_line":"is very small window between api and compute side, also additional"},{"line_number":14,"context_line":"check doesn\u0027t guarantee that live_migration is not already completed"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"7af24918_0fecb5f1","line":11,"updated":"2016-03-03 18:30:53.000000000","message":"rpc to do the check (and therefore more messaging) is a good point. This doesn\u0027t help much.","commit_id":"90ca1b9ddcfdbc4e2bfb2a3bba36639a5816250f"},{"author":{"_account_id":7461,"name":"Paul Murray","email":"pmurray@hpe.com","username":"ptm"},"change_message_id":"276b7edf59a80b8a1c031fa257a0adb1318d0de6","unresolved":false,"context_lines":[{"line_number":10,"context_line":"check of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc requst to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as there"},{"line_number":13,"context_line":"is very small window between api and compute side, also additional"},{"line_number":14,"context_line":"check doesn\u0027t guarantee that live_migration is not already completed"},{"line_number":15,"context_line":"Also target compute host is now taken from migration object rather"},{"line_number":16,"context_line":"then instance.host field. Which allow to guarantee that nova will not"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"7af24918_6f08d9da","line":13,"updated":"2016-03-03 18:30:53.000000000","message":"\"very small window between api and compute\" is only true under ideal operation conditions.","commit_id":"90ca1b9ddcfdbc4e2bfb2a3bba36639a5816250f"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"649de36be3754e15ce3538cca7d972255bf89c94","unresolved":false,"context_lines":[{"line_number":10,"context_line":"check of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc requst to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as there"},{"line_number":13,"context_line":"is very small window between api and compute side, also additional"},{"line_number":14,"context_line":"check doesn\u0027t guarantee that live_migration is not already completed"},{"line_number":15,"context_line":"Also target compute host is now taken from migration object rather"},{"line_number":16,"context_line":"then instance.host field. Which allow to guarantee that nova will not"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"7af24918_1c298a9e","line":13,"in_reply_to":"7af24918_6f08d9da","updated":"2016-03-03 21:29:19.000000000","message":"true, the problem here that when we introduced check on compute side we don\u0027t reduce this window at all, just do more messaging + extra db query.","commit_id":"90ca1b9ddcfdbc4e2bfb2a3bba36639a5816250f"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"474c863f930437bcf3c5a8dcf339b22ba605c56a","unresolved":false,"context_lines":[{"line_number":15,"context_line":"Also target compute host is now taken from migration object rather"},{"line_number":16,"context_line":"then instance.host field. Which allow to guarantee that nova will not"},{"line_number":17,"context_line":"pause already migrated instance."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Change-Id: I51585302e898251e26cbf311aeac38a0ec329001"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"1af94dfe_064ed795","line":18,"updated":"2016-03-16 15:13:59.000000000","message":"Please mention that you add a different check at virt layer, at the moment just for libvirt driver","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"431e4f0951e6480b37c4ff54f47396711d96fccf","unresolved":false,"context_lines":[{"line_number":7,"context_line":"force_live_migration remove redundant check"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"during force_live_migration operation there are 2"},{"line_number":10,"context_line":"check of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc requst to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as there"},{"line_number":13,"context_line":"is very small window between api and compute side, also additional"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7a1b2928_295675d2","line":10,"updated":"2016-04-11 15:07:20.000000000","message":"typo: checks","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"6d879e51512b5a795c32e086b9458821637dc92a","unresolved":false,"context_lines":[{"line_number":7,"context_line":"force_live_migration remove redundant check"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"during force_live_migration operation there are 2"},{"line_number":10,"context_line":"check of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc requst to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as there"},{"line_number":13,"context_line":"is very small window between api and compute side, also additional"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7a1b2928_24c177e5","line":10,"in_reply_to":"7a1b2928_295675d2","updated":"2016-04-11 15:56:11.000000000","message":"Done","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"431e4f0951e6480b37c4ff54f47396711d96fccf","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"during force_live_migration operation there are 2"},{"line_number":10,"context_line":"check of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc requst to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as there"},{"line_number":13,"context_line":"is very small window between api and compute side, also additional"},{"line_number":14,"context_line":"check doesn\u0027t guarantee that live_migration is not already completed"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7a1b2928_695eadea","line":11,"updated":"2016-04-11 15:07:20.000000000","message":"typo: request","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"6d879e51512b5a795c32e086b9458821637dc92a","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"during force_live_migration operation there are 2"},{"line_number":10,"context_line":"check of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc requst to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as there"},{"line_number":13,"context_line":"is very small window between api and compute side, also additional"},{"line_number":14,"context_line":"check doesn\u0027t guarantee that live_migration is not already completed"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7a1b2928_c4b0838e","line":11,"in_reply_to":"7a1b2928_695eadea","updated":"2016-04-11 15:56:11.000000000","message":"Done","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"431e4f0951e6480b37c4ff54f47396711d96fccf","unresolved":false,"context_lines":[{"line_number":10,"context_line":"check of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc requst to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as there"},{"line_number":13,"context_line":"is very small window between api and compute side, also additional"},{"line_number":14,"context_line":"check doesn\u0027t guarantee that live_migration is not already completed"},{"line_number":15,"context_line":"Also target compute host is now taken from migration object rather"},{"line_number":16,"context_line":"then instance.host field. Which allow to guarantee that nova will not"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7a1b2928_0918d91c","line":13,"updated":"2016-04-11 15:07:20.000000000","message":"nit: I\u0027d put the second reason on the first place :)","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"6d879e51512b5a795c32e086b9458821637dc92a","unresolved":false,"context_lines":[{"line_number":10,"context_line":"check of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc requst to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as there"},{"line_number":13,"context_line":"is very small window between api and compute side, also additional"},{"line_number":14,"context_line":"check doesn\u0027t guarantee that live_migration is not already completed"},{"line_number":15,"context_line":"Also target compute host is now taken from migration object rather"},{"line_number":16,"context_line":"then instance.host field. Which allow to guarantee that nova will not"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7a1b2928_97acffee","line":13,"in_reply_to":"7a1b2928_0918d91c","updated":"2016-04-11 15:56:11.000000000","message":"Done","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"ae9b47459b6acbcdf8e523b8fac89e289606bd4d","unresolved":false,"context_lines":[{"line_number":7,"context_line":"force_live_migration remove redundant check"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"During force_live_migration operation there are 2"},{"line_number":10,"context_line":"checks of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc request to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as additional"},{"line_number":13,"context_line":"one doesn\u0027t guarantee that live_migration is not already completed,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"7a1b2928_57d6e7c5","line":10,"updated":"2016-04-11 16:18:55.000000000","message":"oops, forgot to mention this in the previous patch set: looks like both checks are done on the compute side - one in compute manager, another in the libvirt driver","commit_id":"9cb60603292bbcec066070730f2357f21e4aca0d"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"c3a413fb143733ad52da8f4527b29855b52adb84","unresolved":false,"context_lines":[{"line_number":7,"context_line":"force_live_migration remove redundant check"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"During force_live_migration operation there are 2"},{"line_number":10,"context_line":"checks of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc request to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as additional"},{"line_number":13,"context_line":"one doesn\u0027t guarantee that live_migration is not already completed,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"5a18252c_0c2bd9ec","line":10,"in_reply_to":"7a1b2928_57d6e7c5","updated":"2016-04-12 09:42:37.000000000","message":"yes, statement above describes existing behaviour.","commit_id":"9cb60603292bbcec066070730f2357f21e4aca0d"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"d424e4092670c44dba97edbdf9d94765cb147f35","unresolved":false,"context_lines":[{"line_number":9,"context_line":"During force_live_migration operation there are 2"},{"line_number":10,"context_line":"checks of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc request to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as additional"},{"line_number":13,"context_line":"one doesn\u0027t guarantee that live_migration is not already completed,"},{"line_number":14,"context_line":"also is very small window between api and compute side."},{"line_number":15,"context_line":"Target compute host is now taken from migration object rather"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"5a18252c_fd053fc2","line":12,"updated":"2016-04-13 01:00:06.000000000","message":"s/also query to db/also to query the db/","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"5a1babe5fbc9a7663b3b4fc6ec7271427c5e58b5","unresolved":false,"context_lines":[{"line_number":9,"context_line":"During force_live_migration operation there are 2"},{"line_number":10,"context_line":"checks of migration status, one on api layer and one on"},{"line_number":11,"context_line":"compute side, second one requires rpc request to be done"},{"line_number":12,"context_line":"and also query to db. This check could be removed as additional"},{"line_number":13,"context_line":"one doesn\u0027t guarantee that live_migration is not already completed,"},{"line_number":14,"context_line":"also is very small window between api and compute side."},{"line_number":15,"context_line":"Target compute host is now taken from migration object rather"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"5a18252c_635fb341","line":12,"in_reply_to":"5a18252c_fd053fc2","updated":"2016-04-13 13:22:46.000000000","message":"Done","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"e62ddb34517aafde980d66e8b7ed1b0c34e53bfe","unresolved":false,"context_lines":[{"line_number":15,"context_line":"Target compute host is now taken from migration object rather"},{"line_number":16,"context_line":"then instance.host field, which allows to guarantee that nova will not"},{"line_number":17,"context_line":"pause already migrated instance. In case of live-migration failure"},{"line_number":18,"context_line":"paused instance will be resumed on source node."},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"Change-Id: I51585302e898251e26cbf311aeac38a0ec329001"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":18,"id":"dab17558_6cf10ecd","line":18,"range":{"start_line":18,"start_character":46,"end_line":18,"end_character":47},"updated":"2016-05-11 10:45:08.000000000","message":"This commit message is not really saying anything about why and what you\u0027re changing in the libvirt driver. In fact the changes in the libvirt driver are really a separate robustness fix to libvirt migration handling. I think I would have preferred the libvirt driver changes to be a separate commit with explanation of the purpose of the changes, and then this nova rpc API change be a follow-on commit.","commit_id":"5019a7a233d80208d0a703b375b6b65d48a48728"}],"nova/compute/api.py":[{"author":{"_account_id":7461,"name":"Paul Murray","email":"pmurray@hpe.com","username":"ptm"},"change_message_id":"276b7edf59a80b8a1c031fa257a0adb1318d0de6","unresolved":false,"context_lines":[{"line_number":3325,"context_line":"                                                  method\u003d\u0027force complete\u0027)"},{"line_number":3326,"context_line":""},{"line_number":3327,"context_line":"        self.compute_rpcapi.live_migration_force_complete("},{"line_number":3328,"context_line":"            context, instance, migration)"},{"line_number":3329,"context_line":""},{"line_number":3330,"context_line":"    @check_instance_lock"},{"line_number":3331,"context_line":"    @check_instance_cell"}],"source_content_type":"text/x-python","patch_set":1,"id":"7af24918_6fbf3961","line":3328,"updated":"2016-03-03 18:30:53.000000000","message":"migration gets replaced with migration.id in the rpc - so why make this change here?","commit_id":"90ca1b9ddcfdbc4e2bfb2a3bba36639a5816250f"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"649de36be3754e15ce3538cca7d972255bf89c94","unresolved":false,"context_lines":[{"line_number":3325,"context_line":"                                                  method\u003d\u0027force complete\u0027)"},{"line_number":3326,"context_line":""},{"line_number":3327,"context_line":"        self.compute_rpcapi.live_migration_force_complete("},{"line_number":3328,"context_line":"            context, instance, migration)"},{"line_number":3329,"context_line":""},{"line_number":3330,"context_line":"    @check_instance_lock"},{"line_number":3331,"context_line":"    @check_instance_cell"}],"source_content_type":"text/x-python","patch_set":1,"id":"7af24918_fc6bfe1b","line":3328,"in_reply_to":"7af24918_6fbf3961","updated":"2016-03-03 21:29:19.000000000","message":"it\u0027s required to properly get host to do pause, it\u0027s taken from migration object","commit_id":"90ca1b9ddcfdbc4e2bfb2a3bba36639a5816250f"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"a77d397bf13acfeca3233fa3aa9eb9c17cc914a7","unresolved":false,"context_lines":[{"line_number":3415,"context_line":"            context, instance, instance_actions.LIVE_MIGRATION_FORCE_COMPLETE)"},{"line_number":3416,"context_line":""},{"line_number":3417,"context_line":"        self.compute_rpcapi.live_migration_force_complete("},{"line_number":3418,"context_line":"            context, instance, migration)"},{"line_number":3419,"context_line":""},{"line_number":3420,"context_line":"    @check_instance_lock"},{"line_number":3421,"context_line":"    @check_instance_cell"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_d3e83d7f","line":3418,"updated":"2016-04-12 21:00:26.000000000","message":"Why even make this change?","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"}],"nova/compute/manager.py":[{"author":{"_account_id":7461,"name":"Paul Murray","email":"pmurray@hpe.com","username":"ptm"},"change_message_id":"276b7edf59a80b8a1c031fa257a0adb1318d0de6","unresolved":false,"context_lines":[{"line_number":5274,"context_line":"            raise exception.InvalidMigrationState(migration_id\u003dmigration_id,"},{"line_number":5275,"context_line":"                                                  instance_uuid\u003dinstance.uuid,"},{"line_number":5276,"context_line":"                                                  state\u003dmigration.status,"},{"line_number":5277,"context_line":"                                                  method\u003d\u0027force complete\u0027)"},{"line_number":5278,"context_line":""},{"line_number":5279,"context_line":"        self._notify_about_instance_usage("},{"line_number":5280,"context_line":"            context, instance, \u0027live.migration.force.complete.start\u0027)"}],"source_content_type":"text/x-python","patch_set":1,"id":"7af24918_4fe35dd9","side":"PARENT","line":5277,"updated":"2016-03-03 18:30:53.000000000","message":"some kind of local check to replace this would be a good idea. Agree this check is not incredibly useful.","commit_id":"23fdf28daf49d8bf0033d023fb0c73cd69ae5314"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"649de36be3754e15ce3538cca7d972255bf89c94","unresolved":false,"context_lines":[{"line_number":5274,"context_line":"            raise exception.InvalidMigrationState(migration_id\u003dmigration_id,"},{"line_number":5275,"context_line":"                                                  instance_uuid\u003dinstance.uuid,"},{"line_number":5276,"context_line":"                                                  state\u003dmigration.status,"},{"line_number":5277,"context_line":"                                                  method\u003d\u0027force complete\u0027)"},{"line_number":5278,"context_line":""},{"line_number":5279,"context_line":"        self._notify_about_instance_usage("},{"line_number":5280,"context_line":"            context, instance, \u0027live.migration.force.complete.start\u0027)"}],"source_content_type":"text/x-python","patch_set":1,"id":"7af24918_9c63da41","side":"PARENT","line":5277,"in_reply_to":"7af24918_4fe35dd9","updated":"2016-03-03 21:29:19.000000000","message":"Done","commit_id":"23fdf28daf49d8bf0033d023fb0c73cd69ae5314"},{"author":{"_account_id":7461,"name":"Paul Murray","email":"pmurray@hpe.com","username":"ptm"},"change_message_id":"276b7edf59a80b8a1c031fa257a0adb1318d0de6","unresolved":false,"context_lines":[{"line_number":5261,"context_line":""},{"line_number":5262,"context_line":"    @wrap_exception()"},{"line_number":5263,"context_line":"    @wrap_instance_fault"},{"line_number":5264,"context_line":"    def live_migration_force_complete(self, context, instance, migration_id):"},{"line_number":5265,"context_line":"        \"\"\"Force live migration to complete."},{"line_number":5266,"context_line":""},{"line_number":5267,"context_line":"        :param context: Security context"}],"source_content_type":"text/x-python","patch_set":1,"id":"7af24918_2c553fc5","line":5264,"updated":"2016-03-03 18:30:53.000000000","message":"you changed migration_id to migration in the other files.\n\nAlso it doesn\u0027t seem to be used at all in this function.","commit_id":"90ca1b9ddcfdbc4e2bfb2a3bba36639a5816250f"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"649de36be3754e15ce3538cca7d972255bf89c94","unresolved":false,"context_lines":[{"line_number":5261,"context_line":""},{"line_number":5262,"context_line":"    @wrap_exception()"},{"line_number":5263,"context_line":"    @wrap_instance_fault"},{"line_number":5264,"context_line":"    def live_migration_force_complete(self, context, instance, migration_id):"},{"line_number":5265,"context_line":"        \"\"\"Force live migration to complete."},{"line_number":5266,"context_line":""},{"line_number":5267,"context_line":"        :param context: Security context"}],"source_content_type":"text/x-python","patch_set":1,"id":"7af24918_7ccd2e30","line":5264,"in_reply_to":"7af24918_2c553fc5","updated":"2016-03-03 21:29:19.000000000","message":"we need to carry it for backward compatibility during upgrades","commit_id":"90ca1b9ddcfdbc4e2bfb2a3bba36639a5816250f"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"d2a988d37684a236a3bb8c8496574ef010332a25","unresolved":false,"context_lines":[{"line_number":5261,"context_line":""},{"line_number":5262,"context_line":"    @wrap_exception()"},{"line_number":5263,"context_line":"    @wrap_instance_fault"},{"line_number":5264,"context_line":"    def live_migration_force_complete(self, context, instance, migration_id):"},{"line_number":5265,"context_line":"        \"\"\"Force live migration to complete."},{"line_number":5266,"context_line":""},{"line_number":5267,"context_line":"        :param context: Security context"}],"source_content_type":"text/x-python","patch_set":3,"id":"3afc51ec_b1475f4a","line":5264,"range":{"start_line":5264,"start_character":63,"end_line":5264,"end_character":75},"updated":"2016-03-14 09:07:46.000000000","message":"we don\u0027t need migration.id anymore, right?","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"608b81ea949573cfe8546bcc4bfdd51c3a5ed735","unresolved":false,"context_lines":[{"line_number":5261,"context_line":""},{"line_number":5262,"context_line":"    @wrap_exception()"},{"line_number":5263,"context_line":"    @wrap_instance_fault"},{"line_number":5264,"context_line":"    def live_migration_force_complete(self, context, instance, migration_id):"},{"line_number":5265,"context_line":"        \"\"\"Force live migration to complete."},{"line_number":5266,"context_line":""},{"line_number":5267,"context_line":"        :param context: Security context"}],"source_content_type":"text/x-python","patch_set":3,"id":"3afc51ec_b1c0ff2b","line":5264,"range":{"start_line":5264,"start_character":63,"end_line":5264,"end_character":75},"in_reply_to":"3afc51ec_112d7346","updated":"2016-03-14 09:18:22.000000000","message":"sure.","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"a3653f8c83a3b300891cad471a6b9d9c73e68cec","unresolved":false,"context_lines":[{"line_number":5261,"context_line":""},{"line_number":5262,"context_line":"    @wrap_exception()"},{"line_number":5263,"context_line":"    @wrap_instance_fault"},{"line_number":5264,"context_line":"    def live_migration_force_complete(self, context, instance, migration_id):"},{"line_number":5265,"context_line":"        \"\"\"Force live migration to complete."},{"line_number":5266,"context_line":""},{"line_number":5267,"context_line":"        :param context: Security context"}],"source_content_type":"text/x-python","patch_set":3,"id":"3afc51ec_112d7346","line":5264,"range":{"start_line":5264,"start_character":63,"end_line":5264,"end_character":75},"in_reply_to":"3afc51ec_b1475f4a","updated":"2016-03-14 09:13:50.000000000","message":"It\u0027s part of RPC so we can\u0027t just remove it.","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"d2a988d37684a236a3bb8c8496574ef010332a25","unresolved":false,"context_lines":[{"line_number":5266,"context_line":""},{"line_number":5267,"context_line":"        :param context: Security context"},{"line_number":5268,"context_line":"        :param instance: The instance that is being migrated"},{"line_number":5269,"context_line":"        :param migration_id: ID of ongoing migration"},{"line_number":5270,"context_line":""},{"line_number":5271,"context_line":"        \"\"\""},{"line_number":5272,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"3afc51ec_11757397","line":5269,"range":{"start_line":5269,"start_character":8,"end_line":5269,"end_character":52},"updated":"2016-03-14 09:07:46.000000000","message":"ditto","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"608b81ea949573cfe8546bcc4bfdd51c3a5ed735","unresolved":false,"context_lines":[{"line_number":5266,"context_line":""},{"line_number":5267,"context_line":"        :param context: Security context"},{"line_number":5268,"context_line":"        :param instance: The instance that is being migrated"},{"line_number":5269,"context_line":"        :param migration_id: ID of ongoing migration"},{"line_number":5270,"context_line":""},{"line_number":5271,"context_line":"        \"\"\""},{"line_number":5272,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"3afc51ec_d1c5cb3c","line":5269,"range":{"start_line":5269,"start_character":8,"end_line":5269,"end_character":52},"in_reply_to":"3afc51ec_11757397","updated":"2016-03-14 09:18:22.000000000","message":"okay, please clearly say we don\u0027t use this parameter, keep it just for rpc compatible","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"474c863f930437bcf3c5a8dcf339b22ba605c56a","unresolved":false,"context_lines":[{"line_number":5288,"context_line":""},{"line_number":5289,"context_line":"        \"\"\""},{"line_number":5290,"context_line":"        migration \u003d objects.Migration.get_by_id(context, migration_id)"},{"line_number":5291,"context_line":"        if migration.status !\u003d \u0027running\u0027:"},{"line_number":5292,"context_line":"            raise exception.InvalidMigrationState(migration_id\u003dmigration_id,"},{"line_number":5293,"context_line":"                    instance_uuid\u003dinstance.uuid,"},{"line_number":5294,"context_line":"                    state\u003dmigration.status,"},{"line_number":5295,"context_line":"                    method\u003d\u0027abort live migration\u0027)"},{"line_number":5296,"context_line":""},{"line_number":5297,"context_line":"        self._notify_about_instance_usage("},{"line_number":5298,"context_line":"            context, instance, \u0027live.migration.abort.start\u0027)"}],"source_content_type":"text/x-python","patch_set":3,"id":"1af94dfe_813db1bd","line":5295,"range":{"start_line":5291,"start_character":0,"end_line":5295,"end_character":50},"updated":"2016-03-16 15:13:59.000000000","message":"as you are adding a different check for the abort as well in the libvirt driver I think we can remove this check as well.","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"431e4f0951e6480b37c4ff54f47396711d96fccf","unresolved":false,"context_lines":[{"line_number":5332,"context_line":"        :param context: Security context"},{"line_number":5333,"context_line":"        :param instance: The instance that is being migrated"},{"line_number":5334,"context_line":"        :param migration_id: ID of ongoing migration; is currently not used,"},{"line_number":5335,"context_line":"        and isn\u0027t removed in sense of backward compatibility"},{"line_number":5336,"context_line":"        \"\"\""},{"line_number":5337,"context_line":""},{"line_number":5338,"context_line":"        self._notify_about_instance_usage("}],"source_content_type":"text/x-python","patch_set":5,"id":"7a1b2928_e9f8fd7e","line":5335,"updated":"2016-04-11 15:07:20.000000000","message":"nit: maybe make it optional then?","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"6d879e51512b5a795c32e086b9458821637dc92a","unresolved":false,"context_lines":[{"line_number":5332,"context_line":"        :param context: Security context"},{"line_number":5333,"context_line":"        :param instance: The instance that is being migrated"},{"line_number":5334,"context_line":"        :param migration_id: ID of ongoing migration; is currently not used,"},{"line_number":5335,"context_line":"        and isn\u0027t removed in sense of backward compatibility"},{"line_number":5336,"context_line":"        \"\"\""},{"line_number":5337,"context_line":""},{"line_number":5338,"context_line":"        self._notify_about_instance_usage("}],"source_content_type":"text/x-python","patch_set":5,"id":"7a1b2928_442bd3eb","line":5335,"in_reply_to":"7a1b2928_e9f8fd7e","updated":"2016-04-11 15:56:11.000000000","message":"Done","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"a77d397bf13acfeca3233fa3aa9eb9c17cc914a7","unresolved":false,"context_lines":[{"line_number":5326,"context_line":"    @wrap_exception()"},{"line_number":5327,"context_line":"    @wrap_instance_event"},{"line_number":5328,"context_line":"    @wrap_instance_fault"},{"line_number":5329,"context_line":"    def live_migration_force_complete(self, context, instance,"},{"line_number":5330,"context_line":"                                      migration_id\u003dNone):"},{"line_number":5331,"context_line":"        \"\"\"Force live migration to complete."},{"line_number":5332,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_73f32974","line":5329,"updated":"2016-04-12 21:00:26.000000000","message":"Put a comment on this method about removing migration_id in whatever version when we bump. See this file for other examples.","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"5a1babe5fbc9a7663b3b4fc6ec7271427c5e58b5","unresolved":false,"context_lines":[{"line_number":5326,"context_line":"    @wrap_exception()"},{"line_number":5327,"context_line":"    @wrap_instance_event"},{"line_number":5328,"context_line":"    @wrap_instance_fault"},{"line_number":5329,"context_line":"    def live_migration_force_complete(self, context, instance,"},{"line_number":5330,"context_line":"                                      migration_id\u003dNone):"},{"line_number":5331,"context_line":"        \"\"\"Force live migration to complete."},{"line_number":5332,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_48c0d47c","line":5329,"in_reply_to":"5a18252c_73f32974","updated":"2016-04-13 13:22:46.000000000","message":"Done","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"d424e4092670c44dba97edbdf9d94765cb147f35","unresolved":false,"context_lines":[{"line_number":5333,"context_line":"        :param context: Security context"},{"line_number":5334,"context_line":"        :param instance: The instance that is being migrated"},{"line_number":5335,"context_line":"        :param migration_id: ID of ongoing migration; is currently not used,"},{"line_number":5336,"context_line":"        and isn\u0027t removed in sense of backward compatibility"},{"line_number":5337,"context_line":"        \"\"\""},{"line_number":5338,"context_line":""},{"line_number":5339,"context_line":"        self._notify_about_instance_usage("}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_9d688b89","line":5336,"updated":"2016-04-13 01:00:06.000000000","message":"AFAIK, you will still need to increment the RPC API version, so that there is a breadcrumb trail where we know an argument was deprecated...","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"a77d397bf13acfeca3233fa3aa9eb9c17cc914a7","unresolved":false,"context_lines":[{"line_number":5333,"context_line":"        :param context: Security context"},{"line_number":5334,"context_line":"        :param instance: The instance that is being migrated"},{"line_number":5335,"context_line":"        :param migration_id: ID of ongoing migration; is currently not used,"},{"line_number":5336,"context_line":"        and isn\u0027t removed in sense of backward compatibility"},{"line_number":5337,"context_line":"        \"\"\""},{"line_number":5338,"context_line":""},{"line_number":5339,"context_line":"        self._notify_about_instance_usage("}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_53e6edb4","line":5336,"range":{"start_line":5336,"start_character":26,"end_line":5336,"end_character":37},"updated":"2016-04-12 21:00:26.000000000","message":"just \"for\" here would be fine.","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"5a1babe5fbc9a7663b3b4fc6ec7271427c5e58b5","unresolved":false,"context_lines":[{"line_number":5333,"context_line":"        :param context: Security context"},{"line_number":5334,"context_line":"        :param instance: The instance that is being migrated"},{"line_number":5335,"context_line":"        :param migration_id: ID of ongoing migration; is currently not used,"},{"line_number":5336,"context_line":"        and isn\u0027t removed in sense of backward compatibility"},{"line_number":5337,"context_line":"        \"\"\""},{"line_number":5338,"context_line":""},{"line_number":5339,"context_line":"        self._notify_about_instance_usage("}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_3f0de237","line":5336,"range":{"start_line":5336,"start_character":26,"end_line":5336,"end_character":37},"in_reply_to":"5a18252c_53e6edb4","updated":"2016-04-13 13:22:46.000000000","message":"Done","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"5a1babe5fbc9a7663b3b4fc6ec7271427c5e58b5","unresolved":false,"context_lines":[{"line_number":5333,"context_line":"        :param context: Security context"},{"line_number":5334,"context_line":"        :param instance: The instance that is being migrated"},{"line_number":5335,"context_line":"        :param migration_id: ID of ongoing migration; is currently not used,"},{"line_number":5336,"context_line":"        and isn\u0027t removed in sense of backward compatibility"},{"line_number":5337,"context_line":"        \"\"\""},{"line_number":5338,"context_line":""},{"line_number":5339,"context_line":"        self._notify_about_instance_usage("}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_4b21fb4c","line":5336,"in_reply_to":"5a18252c_9d688b89","updated":"2016-04-13 13:22:46.000000000","message":"Done","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"6e6f0a0533e0775493ec22378d3feb92686b0233","unresolved":false,"context_lines":[{"line_number":5324,"context_line":"                      migrate_data)"},{"line_number":5325,"context_line":""},{"line_number":5326,"context_line":"    # NOTE(tdurakov): migration_id is used since 4.12 rpc api version"},{"line_number":5327,"context_line":"    # remove migration_id parameter on Newton EOL."},{"line_number":5328,"context_line":"    @wrap_exception()"},{"line_number":5329,"context_line":"    @wrap_instance_event"},{"line_number":5330,"context_line":"    @wrap_instance_fault"}],"source_content_type":"text/x-python","patch_set":11,"id":"1a122d0e_79f17fcd","line":5327,"range":{"start_line":5327,"start_character":5,"end_line":5327,"end_character":50},"updated":"2016-04-15 11:07:59.000000000","message":"I am wonder if a TODO makes it easier to spot it at the end of Newton","commit_id":"c1550da469b7b3769f126438e5b16f4f36a0c994"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"0e52c13350c9b8caa5743692248f4d352d0ba598","unresolved":false,"context_lines":[{"line_number":5326,"context_line":"                      migrate_data)"},{"line_number":5327,"context_line":""},{"line_number":5328,"context_line":"    # TODO(tdurakov): migration_id is used since 4.12 rpc api version"},{"line_number":5329,"context_line":"    # remove migration_id parameter on Newton EOL."},{"line_number":5330,"context_line":"    @wrap_exception()"},{"line_number":5331,"context_line":"    @wrap_instance_event"},{"line_number":5332,"context_line":"    @wrap_instance_fault"}],"source_content_type":"text/x-python","patch_set":13,"id":"1a122d0e_464df298","line":5329,"updated":"2016-04-20 16:31:08.000000000","message":"Sorry I didn\u0027t catch this before. The parameter can be removed when the RPC version is bumped to 5.x. That may not be the same time as Newton EOL.","commit_id":"b7639c4b27ce4a0bdb50741354c2ecb0fd22ceb2"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"5e40aa6803a29fdd0b985641e680afc202952c48","unresolved":false,"context_lines":[{"line_number":5326,"context_line":"                      migrate_data)"},{"line_number":5327,"context_line":""},{"line_number":5328,"context_line":"    # TODO(tdurakov): migration_id is used since 4.12 rpc api version"},{"line_number":5329,"context_line":"    # remove migration_id parameter on Newton EOL."},{"line_number":5330,"context_line":"    @wrap_exception()"},{"line_number":5331,"context_line":"    @wrap_instance_event"},{"line_number":5332,"context_line":"    @wrap_instance_fault"}],"source_content_type":"text/x-python","patch_set":13,"id":"1a122d0e_718266c9","line":5329,"in_reply_to":"1a122d0e_464df298","updated":"2016-04-20 16:43:27.000000000","message":"Done","commit_id":"b7639c4b27ce4a0bdb50741354c2ecb0fd22ceb2"}],"nova/compute/rpcapi.py":[{"author":{"_account_id":12175,"name":"Eli Qiao","email":"qiaoliyong@gmail.com","username":"Eli"},"change_message_id":"d2a988d37684a236a3bb8c8496574ef010332a25","unresolved":false,"context_lines":[{"line_number":654,"context_line":"        version \u003d \u00274.9\u0027"},{"line_number":655,"context_line":"        cctxt \u003d self.client.prepare(server\u003d_compute_host("},{"line_number":656,"context_line":"            migration.source_compute, instance), version\u003dversion)"},{"line_number":657,"context_line":"        cctxt.cast(ctxt, \u0027live_migration_force_complete\u0027, instance\u003dinstance,"},{"line_number":658,"context_line":"                   migration_id\u003dmigration.id)"},{"line_number":659,"context_line":""},{"line_number":660,"context_line":"    def live_migration_abort(self, ctxt, instance, migration_id):"}],"source_content_type":"text/x-python","patch_set":3,"id":"3afc51ec_31a98fe0","line":657,"range":{"start_line":657,"start_character":14,"end_line":657,"end_character":19},"updated":"2016-03-14 09:07:46.000000000","message":"should be a call?","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"a3653f8c83a3b300891cad471a6b9d9c73e68cec","unresolved":false,"context_lines":[{"line_number":654,"context_line":"        version \u003d \u00274.9\u0027"},{"line_number":655,"context_line":"        cctxt \u003d self.client.prepare(server\u003d_compute_host("},{"line_number":656,"context_line":"            migration.source_compute, instance), version\u003dversion)"},{"line_number":657,"context_line":"        cctxt.cast(ctxt, \u0027live_migration_force_complete\u0027, instance\u003dinstance,"},{"line_number":658,"context_line":"                   migration_id\u003dmigration.id)"},{"line_number":659,"context_line":""},{"line_number":660,"context_line":"    def live_migration_abort(self, ctxt, instance, migration_id):"}],"source_content_type":"text/x-python","patch_set":3,"id":"3afc51ec_312a2f2d","line":657,"range":{"start_line":657,"start_character":14,"end_line":657,"end_character":19},"in_reply_to":"3afc51ec_31a98fe0","updated":"2016-03-14 09:13:50.000000000","message":"Cast is good there, we want it to be async.","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"431e4f0951e6480b37c4ff54f47396711d96fccf","unresolved":false,"context_lines":[{"line_number":646,"context_line":"        cctxt \u003d self.client.prepare(server\u003d_compute_host("},{"line_number":647,"context_line":"            migration.source_compute, instance), version\u003dversion)"},{"line_number":648,"context_line":"        cctxt.cast(ctxt, \u0027live_migration_force_complete\u0027, instance\u003dinstance,"},{"line_number":649,"context_line":"                   migration_id\u003dmigration.id)"},{"line_number":650,"context_line":""},{"line_number":651,"context_line":"    def live_migration_abort(self, ctxt, instance, migration_id):"},{"line_number":652,"context_line":"        version \u003d \u00274.10\u0027"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a1b2928_e96d9d33","line":649,"updated":"2016-04-11 15:07:20.000000000","message":"just a note to myself: we just change the function signature on the RPC client side, the id value is still passed to the RPC server, not an object","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"a77d397bf13acfeca3233fa3aa9eb9c17cc914a7","unresolved":false,"context_lines":[{"line_number":642,"context_line":"                   migrate_data\u003dmigrate_data, **args)"},{"line_number":643,"context_line":""},{"line_number":644,"context_line":"    def live_migration_force_complete(self, ctxt, instance, migration):"},{"line_number":645,"context_line":"        version \u003d \u00274.9\u0027"},{"line_number":646,"context_line":"        cctxt \u003d self.client.prepare(server\u003d_compute_host("},{"line_number":647,"context_line":"            migration.source_compute, instance), version\u003dversion)"},{"line_number":648,"context_line":"        cctxt.cast(ctxt, \u0027live_migration_force_complete\u0027, instance\u003dinstance,"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_f37459d0","line":645,"updated":"2016-04-12 21:00:26.000000000","message":"I would bump the version to deprecate and stop passing the parameter if we\u0027re sufficiently new. That will make the rollover to the next version easier.","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"a77d397bf13acfeca3233fa3aa9eb9c17cc914a7","unresolved":false,"context_lines":[{"line_number":644,"context_line":"    def live_migration_force_complete(self, ctxt, instance, migration):"},{"line_number":645,"context_line":"        version \u003d \u00274.9\u0027"},{"line_number":646,"context_line":"        cctxt \u003d self.client.prepare(server\u003d_compute_host("},{"line_number":647,"context_line":"            migration.source_compute, instance), version\u003dversion)"},{"line_number":648,"context_line":"        cctxt.cast(ctxt, \u0027live_migration_force_complete\u0027, instance\u003dinstance,"},{"line_number":649,"context_line":"                   migration_id\u003dmigration.id)"},{"line_number":650,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_939525e6","line":647,"updated":"2016-04-12 21:00:26.000000000","message":"Oh I guess because you want this? Makes sense.","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"5a1babe5fbc9a7663b3b4fc6ec7271427c5e58b5","unresolved":false,"context_lines":[{"line_number":644,"context_line":"    def live_migration_force_complete(self, ctxt, instance, migration):"},{"line_number":645,"context_line":"        version \u003d \u00274.9\u0027"},{"line_number":646,"context_line":"        cctxt \u003d self.client.prepare(server\u003d_compute_host("},{"line_number":647,"context_line":"            migration.source_compute, instance), version\u003dversion)"},{"line_number":648,"context_line":"        cctxt.cast(ctxt, \u0027live_migration_force_complete\u0027, instance\u003dinstance,"},{"line_number":649,"context_line":"                   migration_id\u003dmigration.id)"},{"line_number":650,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_df35ceda","line":647,"in_reply_to":"5a18252c_939525e6","updated":"2016-04-13 13:22:46.000000000","message":"yes, to be confident that nova won\u0027t pause already migrated instance.","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"}],"nova/tests/unit/compute/test_rpcapi.py":[{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"d424e4092670c44dba97edbdf9d94765cb147f35","unresolved":false,"context_lines":[{"line_number":89,"context_line":"        mock_get_min.assert_called_once_with(mock.ANY, \u0027nova-compute\u0027)"},{"line_number":90,"context_line":"        self.assertEqual(\u00274.4\u0027, compute_rpcapi.LAST_VERSION)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def _test_compute_api(self, method, rpc_method,"},{"line_number":93,"context_line":"                          expected_args\u003dNone, **kwargs):"},{"line_number":94,"context_line":"        ctxt \u003d context.RequestContext(\u0027fake_user\u0027, \u0027fake_project\u0027)"},{"line_number":95,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_dd0843dc","line":92,"updated":"2016-04-13 01:00:06.000000000","message":"This test method has become too big for its britches, IMHO. Very difficult to tell what is actually being asserted :(","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"f4e4afeae76b1201db951320d39abe0a69d15701","unresolved":false,"context_lines":[{"line_number":89,"context_line":"        mock_get_min.assert_called_once_with(mock.ANY, \u0027nova-compute\u0027)"},{"line_number":90,"context_line":"        self.assertEqual(\u00274.4\u0027, compute_rpcapi.LAST_VERSION)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def _test_compute_api(self, method, rpc_method,"},{"line_number":93,"context_line":"                          expected_args\u003dNone, **kwargs):"},{"line_number":94,"context_line":"        ctxt \u003d context.RequestContext(\u0027fake_user\u0027, \u0027fake_project\u0027)"},{"line_number":95,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_745e5813","line":92,"in_reply_to":"5a18252c_dd0843dc","updated":"2016-04-13 10:28:59.000000000","message":"It\u0027s not even a test method, it\u0027s a helper...the way in which it is habitual for nova tests to abstract assertions away from the actual test method is painful for the reader. I get that DRY is nice, but ugh.","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"5a1babe5fbc9a7663b3b4fc6ec7271427c5e58b5","unresolved":false,"context_lines":[{"line_number":89,"context_line":"        mock_get_min.assert_called_once_with(mock.ANY, \u0027nova-compute\u0027)"},{"line_number":90,"context_line":"        self.assertEqual(\u00274.4\u0027, compute_rpcapi.LAST_VERSION)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def _test_compute_api(self, method, rpc_method,"},{"line_number":93,"context_line":"                          expected_args\u003dNone, **kwargs):"},{"line_number":94,"context_line":"        ctxt \u003d context.RequestContext(\u0027fake_user\u0027, \u0027fake_project\u0027)"},{"line_number":95,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a18252c_8b6dd39a","line":92,"in_reply_to":"5a18252c_dd0843dc","updated":"2016-04-13 13:22:46.000000000","message":"agree, rewrote testing logic for test_live_migration_force_complete, so not making _test_compute_api more complex","commit_id":"6c6b954d1179f9ee97a1afc5e5be275294540004"}],"nova/tests/unit/virt/libvirt/test_driver.py":[{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"e9cb1b14cf169037bc229a98ac3aba4c05ceb9cf","unresolved":false,"context_lines":[{"line_number":7696,"context_line":"                    mock_abort.called,"},{"line_number":7697,"context_line":"                    \u0027abortJob not called when failure expected\u0027)"},{"line_number":7698,"context_line":"            self.assertFalse("},{"line_number":7699,"context_line":"                fake_post_method.called,"},{"line_number":7700,"context_line":"                \u0027Post method called when success not expected\u0027)"},{"line_number":7701,"context_line":"            if expected_mig_status:"},{"line_number":7702,"context_line":"                fake_recover_method.assert_called_once_with("}],"source_content_type":"text/x-python","patch_set":12,"id":"1a122d0e_f4f85fc5","line":7699,"updated":"2016-04-19 19:05:23.000000000","message":"All of these whitespace changes make it more difficult to focus on the actual changes in the patch.","commit_id":"916947b09f9f946734551e137dce84d52cefda3f"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"09ad5ac2280c274c9d76f78e83b7487123f031f0","unresolved":false,"context_lines":[{"line_number":7696,"context_line":"                    mock_abort.called,"},{"line_number":7697,"context_line":"                    \u0027abortJob not called when failure expected\u0027)"},{"line_number":7698,"context_line":"            self.assertFalse("},{"line_number":7699,"context_line":"                fake_post_method.called,"},{"line_number":7700,"context_line":"                \u0027Post method called when success not expected\u0027)"},{"line_number":7701,"context_line":"            if expected_mig_status:"},{"line_number":7702,"context_line":"                fake_recover_method.assert_called_once_with("}],"source_content_type":"text/x-python","patch_set":12,"id":"1a122d0e_7a988d1c","line":7699,"in_reply_to":"1a122d0e_14299be6","updated":"2016-04-20 13:45:02.000000000","message":"Done","commit_id":"916947b09f9f946734551e137dce84d52cefda3f"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2499d02dc9c7c8c97a766b1f7dc0e298f601f805","unresolved":false,"context_lines":[{"line_number":7696,"context_line":"                    mock_abort.called,"},{"line_number":7697,"context_line":"                    \u0027abortJob not called when failure expected\u0027)"},{"line_number":7698,"context_line":"            self.assertFalse("},{"line_number":7699,"context_line":"                fake_post_method.called,"},{"line_number":7700,"context_line":"                \u0027Post method called when success not expected\u0027)"},{"line_number":7701,"context_line":"            if expected_mig_status:"},{"line_number":7702,"context_line":"                fake_recover_method.assert_called_once_with("}],"source_content_type":"text/x-python","patch_set":12,"id":"1a122d0e_14299be6","line":7699,"in_reply_to":"1a122d0e_f4f85fc5","updated":"2016-04-19 19:11:02.000000000","message":"Yeah, agreed.","commit_id":"916947b09f9f946734551e137dce84d52cefda3f"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"2d408f099731de06c51bd1e754e4845861f7ec3f","unresolved":false,"context_lines":[{"line_number":6545,"context_line":"        domain \u003d guest._domain"},{"line_number":6546,"context_line":"        info \u003d host.DomainJobInfo.for_domain(domain)"},{"line_number":6547,"context_line":"        if (info.type \u003d\u003d libvirt.VIR_DOMAIN_JOB_UNBOUNDED or"},{"line_number":6548,"context_line":"            info.type \u003d\u003d libvirt.VIR_DOMAIN_JOB_BOUNDED):"},{"line_number":6549,"context_line":"            self.pause(instance)"},{"line_number":6550,"context_line":""},{"line_number":6551,"context_line":"    def _try_fetch_image(self, context, path, image_id, instance,"}],"source_content_type":"text/x-python","patch_set":2,"id":"7af24918_b91a0fc4","line":6548,"range":{"start_line":6548,"start_character":55,"end_line":6548,"end_character":57},"updated":"2016-03-04 09:45:32.000000000","message":"This is really not right - there are multiple things in libvirt which can run jobs against the VM, not only migration. In particular save \u0026 restore will do so.\n\nNova already knows whether a VM is in a migration state or not, so we should be checking the VM state \u003d\u003d \"migrating\" which is much more accurate that what\u0027s done here.","commit_id":"7774c615735d5346b5362b0ad6af4680409459d2"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"90b38e0c13510b2a1c95b691089fe0a9ec0f5b08","unresolved":false,"context_lines":[{"line_number":6545,"context_line":"        domain \u003d guest._domain"},{"line_number":6546,"context_line":"        info \u003d host.DomainJobInfo.for_domain(domain)"},{"line_number":6547,"context_line":"        if (info.type \u003d\u003d libvirt.VIR_DOMAIN_JOB_UNBOUNDED or"},{"line_number":6548,"context_line":"            info.type \u003d\u003d libvirt.VIR_DOMAIN_JOB_BOUNDED):"},{"line_number":6549,"context_line":"            self.pause(instance)"},{"line_number":6550,"context_line":""},{"line_number":6551,"context_line":"    def _try_fetch_image(self, context, path, image_id, instance,"}],"source_content_type":"text/x-python","patch_set":2,"id":"7af24918_3f289f32","line":6548,"range":{"start_line":6548,"start_character":55,"end_line":6548,"end_character":57},"in_reply_to":"7af24918_b91a0fc4","updated":"2016-03-04 10:16:17.000000000","message":"There is another way to solve this. We already have an asynchronous thread that is running in the background monitoring the migration job. That threads knows exactly when the migration job starts \u0026 ends.\n\nSo to make this totally race-free, we should delegate the job of invoking pause() to that thread.\n\nSpecifically I\u0027m refering to the _live_migration_monitor() method which loops running host.DomainJobInfo.for_domain().\n\nWhat we want is for this live_migration_force_complete() method to set some kind of flag / state somewhere. The _live_migration_monitor() method would detect when that flag was set, and then call vm.pause()","commit_id":"7774c615735d5346b5362b0ad6af4680409459d2"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"54fa3f60e30ba26d929c3cb0e59d3381d2051180","unresolved":false,"context_lines":[{"line_number":6303,"context_line":"                    task \u003d self.active_migrations.get(instance, None)"},{"line_number":6304,"context_line":"                    if task is not None:"},{"line_number":6305,"context_line":"                        if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6306,"context_line":"                            self.pause(instance)"},{"line_number":6307,"context_line":"                        elif task \u003d\u003d \u0027abort\u0027:"},{"line_number":6308,"context_line":"                            try:"},{"line_number":6309,"context_line":"                                dom.abortJob()"}],"source_content_type":"text/x-python","patch_set":3,"id":"7af24918_6c4f1534","line":6306,"range":{"start_line":6306,"start_character":47,"end_line":6306,"end_character":48},"updated":"2016-03-04 14:16:26.000000000","message":"We must catch \u0026 ignore any exception here to ensure we carry on monitoring until completion","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"54fa3f60e30ba26d929c3cb0e59d3381d2051180","unresolved":false,"context_lines":[{"line_number":6310,"context_line":"                            except libvirt.libvirtError as e:"},{"line_number":6311,"context_line":"                                LOG.warn(_LW(\"Failed to abort migration %s\"),"},{"line_number":6312,"context_line":"                                         e, instance\u003dinstance)"},{"line_number":6313,"context_line":"                                raise"},{"line_number":6314,"context_line":"                        self.active_migrations[instance] \u003d None"},{"line_number":6315,"context_line":"                    # Leave type untouched"},{"line_number":6316,"context_line":"                else:"}],"source_content_type":"text/x-python","patch_set":3,"id":"7af24918_4c4e993b","line":6313,"range":{"start_line":6313,"start_character":32,"end_line":6313,"end_character":37},"updated":"2016-03-04 14:16:26.000000000","message":"No, we should not raise an exception. We must carry on monitoring the migration until we get the job finishes","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"14d466b58fc70cce3bba8465c6bfae8fed0a6c49","unresolved":false,"context_lines":[{"line_number":6556,"context_line":"        # NOTE(pkoniszewski): currently only pause during live migration is"},{"line_number":6557,"context_line":"        # supported to force live migration to complete, so just try to pause"},{"line_number":6558,"context_line":"        # the instance"},{"line_number":6559,"context_line":"        self.active_migrations[instance] \u003d \u0027pause\u0027"},{"line_number":6560,"context_line":""},{"line_number":6561,"context_line":"    def _try_fetch_image(self, context, path, image_id, instance,"},{"line_number":6562,"context_line":"                         fallback_from_host\u003dNone):"}],"source_content_type":"text/x-python","patch_set":3,"id":"7af24918_47cdd264","line":6559,"updated":"2016-03-04 14:34:42.000000000","message":"We don\u0027t have guarantee here that this instance will be the same that instance in the monitor. It will be way safer to use instance.uuid instead, which is unique and will not change over time, like instance.progress does.","commit_id":"02e7863ed18b1ebb7f0caaca84598f6afe061504"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"431e4f0951e6480b37c4ff54f47396711d96fccf","unresolved":false,"context_lines":[{"line_number":6245,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6246,"context_line":"                    try:"},{"line_number":6247,"context_line":"                        self.pause(instance)"},{"line_number":6248,"context_line":"                        self.active_migrations[instance.uuid] \u003d None"},{"line_number":6249,"context_line":"                    except Exception as e:"},{"line_number":6250,"context_line":"                        LOG.warn(_LW(\"Failed to pause instance during\""},{"line_number":6251,"context_line":"                                     \"live-migration %s\"),"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a1b2928_f4f8d47e","line":6248,"updated":"2016-04-11 15:07:20.000000000","message":"Maybe use an empty deque instead? (should someone try to force completion again, which would do an append())","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"431e4f0951e6480b37c4ff54f47396711d96fccf","unresolved":false,"context_lines":[{"line_number":6444,"context_line":"                         info.type, instance\u003dinstance)"},{"line_number":6445,"context_line":""},{"line_number":6446,"context_line":"            time.sleep(0.5)"},{"line_number":6447,"context_line":"        if instance.uuid in self.active_migrations:"},{"line_number":6448,"context_line":"            del self.active_migrations[instance.uuid]"},{"line_number":6449,"context_line":"        else:"},{"line_number":6450,"context_line":"            LOG.warn(_LW(\"There are no records in \""}],"source_content_type":"text/x-python","patch_set":5,"id":"7a1b2928_d4a03893","line":6447,"updated":"2016-04-11 15:07:20.000000000","message":"How about doing:\n\n  try:\n     del self.active_migrations[instance.uuid]\n  except KeyError:\n      LOG.warn(...)\n\ninstead?","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"6d879e51512b5a795c32e086b9458821637dc92a","unresolved":false,"context_lines":[{"line_number":6444,"context_line":"                         info.type, instance\u003dinstance)"},{"line_number":6445,"context_line":""},{"line_number":6446,"context_line":"            time.sleep(0.5)"},{"line_number":6447,"context_line":"        if instance.uuid in self.active_migrations:"},{"line_number":6448,"context_line":"            del self.active_migrations[instance.uuid]"},{"line_number":6449,"context_line":"        else:"},{"line_number":6450,"context_line":"            LOG.warn(_LW(\"There are no records in \""}],"source_content_type":"text/x-python","patch_set":5,"id":"7a1b2928_44ee338c","line":6447,"in_reply_to":"7a1b2928_d4a03893","updated":"2016-04-11 15:56:11.000000000","message":"Done","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"431e4f0951e6480b37c4ff54f47396711d96fccf","unresolved":false,"context_lines":[{"line_number":6524,"context_line":"        # NOTE(pkoniszewski): currently only pause during live migration is"},{"line_number":6525,"context_line":"        # supported to force live migration to complete, so just try to pause"},{"line_number":6526,"context_line":"        # the instance"},{"line_number":6527,"context_line":"        if instance.uuid not in self.active_migrations:"},{"line_number":6528,"context_line":"            raise exception.NoActiveMigrationForInstance("},{"line_number":6529,"context_line":"                instance_id\u003dinstance.uuid)"},{"line_number":6530,"context_line":"        self.active_migrations[instance.uuid].append(\u0027pause\u0027)"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a1b2928_344c0c70","line":6527,"updated":"2016-04-11 15:07:20.000000000","message":"How about changing this to:\n\n  try:\n     self.active_migrations[instance.uuid].append(\u0027pause\u0027)\n  except KeyError:\n     raise exception.NoActiveMigrationForInstance(instance_id\u003dinstance.uuid)\n\n?\n\n1) you would avoid doing a check in the optimistic case\n2) you would not need a lock here (e.g. if native threads were used), as both [key] and append() operations are atomic in CPython","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"6d879e51512b5a795c32e086b9458821637dc92a","unresolved":false,"context_lines":[{"line_number":6524,"context_line":"        # NOTE(pkoniszewski): currently only pause during live migration is"},{"line_number":6525,"context_line":"        # supported to force live migration to complete, so just try to pause"},{"line_number":6526,"context_line":"        # the instance"},{"line_number":6527,"context_line":"        if instance.uuid not in self.active_migrations:"},{"line_number":6528,"context_line":"            raise exception.NoActiveMigrationForInstance("},{"line_number":6529,"context_line":"                instance_id\u003dinstance.uuid)"},{"line_number":6530,"context_line":"        self.active_migrations[instance.uuid].append(\u0027pause\u0027)"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a1b2928_04e6fbb3","line":6527,"in_reply_to":"7a1b2928_344c0c70","updated":"2016-04-11 15:56:11.000000000","message":"Done","commit_id":"5f0cfba37d763374ad1caf10a3d52c869e9920e8"},{"author":{"_account_id":10618,"name":"Pavel Kholkin","email":"p.v.holkin@mail.ru","username":"pkholkin"},"change_message_id":"4437f4b7c881d7abcfc4c993e502ff419fef7956","unresolved":false,"context_lines":[{"line_number":6246,"context_line":"                    try:"},{"line_number":6247,"context_line":"                        self.pause(instance)"},{"line_number":6248,"context_line":"                    except Exception as e:"},{"line_number":6249,"context_line":"                        LOG.warn(_LW(\"Failed to pause instance during\""},{"line_number":6250,"context_line":"                                     \"live-migration %s\"),"},{"line_number":6251,"context_line":"                                 e, instance\u003dinstance)"},{"line_number":6252,"context_line":""},{"line_number":6253,"context_line":"        n \u003d 0"}],"source_content_type":"text/x-python","patch_set":6,"id":"7a1b2928_1a2bf683","line":6250,"range":{"start_line":6249,"start_character":69,"end_line":6250,"end_character":38},"updated":"2016-04-11 16:16:15.000000000","message":"please add backspace (\" \") between these words","commit_id":"9cb60603292bbcec066070730f2357f21e4aca0d"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"a706d2345d5a7fa7d544cf37cc4dbf195c6318de","unresolved":false,"context_lines":[{"line_number":6246,"context_line":"                    try:"},{"line_number":6247,"context_line":"                        self.pause(instance)"},{"line_number":6248,"context_line":"                    except Exception as e:"},{"line_number":6249,"context_line":"                        LOG.warn(_LW(\"Failed to pause instance during\""},{"line_number":6250,"context_line":"                                     \"live-migration %s\"),"},{"line_number":6251,"context_line":"                                 e, instance\u003dinstance)"},{"line_number":6252,"context_line":""},{"line_number":6253,"context_line":"        n \u003d 0"}],"source_content_type":"text/x-python","patch_set":6,"id":"5a18252c_a973b74c","line":6250,"range":{"start_line":6249,"start_character":69,"end_line":6250,"end_character":38},"in_reply_to":"7a1b2928_1a2bf683","updated":"2016-04-12 09:40:24.000000000","message":"Done","commit_id":"9cb60603292bbcec066070730f2357f21e4aca0d"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"46abd9465fb800e953773c28463b50681831fbd8","unresolved":false,"context_lines":[{"line_number":6339,"context_line":"                    except libvirt.libvirtError as e:"},{"line_number":6340,"context_line":"                        LOG.warning(_LW(\"Failed to abort migration %s\"),"},{"line_number":6341,"context_line":"                                 e, instance\u003dinstance)"},{"line_number":6342,"context_line":"                        raise"},{"line_number":6343,"context_line":""},{"line_number":6344,"context_line":"                # See if we need to increase the max downtime. We"},{"line_number":6345,"context_line":"                # ignore failures, since we\u0027d rather continue trying"}],"source_content_type":"text/x-python","patch_set":7,"id":"5a18252c_773a1acf","line":6342,"updated":"2016-04-12 09:54:30.000000000","message":"If exception is raised here you won\u0027t cleanup active_migrations dict. It might lead to weird cases where you already accept tasks and then you just remove them all at line 6496","commit_id":"2b927c679f4269a4ca280e45f6696a11fa7aa6ee"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"1ca35d5454d61e66733e38f37c017a3648e797a6","unresolved":false,"context_lines":[{"line_number":6339,"context_line":"                    except libvirt.libvirtError as e:"},{"line_number":6340,"context_line":"                        LOG.warning(_LW(\"Failed to abort migration %s\"),"},{"line_number":6341,"context_line":"                                 e, instance\u003dinstance)"},{"line_number":6342,"context_line":"                        raise"},{"line_number":6343,"context_line":""},{"line_number":6344,"context_line":"                # See if we need to increase the max downtime. We"},{"line_number":6345,"context_line":"                # ignore failures, since we\u0027d rather continue trying"}],"source_content_type":"text/x-python","patch_set":7,"id":"5a18252c_f6cbc31c","line":6342,"in_reply_to":"5a18252c_773a1acf","updated":"2016-04-12 12:56:45.000000000","message":"good catch","commit_id":"2b927c679f4269a4ca280e45f6696a11fa7aa6ee"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"46abd9465fb800e953773c28463b50681831fbd8","unresolved":false,"context_lines":[{"line_number":6443,"context_line":"                         info.type, instance\u003dinstance)"},{"line_number":6444,"context_line":""},{"line_number":6445,"context_line":"            time.sleep(0.5)"},{"line_number":6446,"context_line":"        try:"},{"line_number":6447,"context_line":"            del self.active_migrations[instance.uuid]"},{"line_number":6448,"context_line":"        except KeyError:"},{"line_number":6449,"context_line":"            LOG.warn(_LW(\"There are no records in \""}],"source_content_type":"text/x-python","patch_set":7,"id":"5a18252c_ec35bdf7","line":6446,"updated":"2016-04-12 09:54:30.000000000","message":"This can be a simple if-else instead of coding by exception.","commit_id":"2b927c679f4269a4ca280e45f6696a11fa7aa6ee"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"f31975f387f97c722224fa8f72e646bbe3f727d9","unresolved":false,"context_lines":[{"line_number":6443,"context_line":"                         info.type, instance\u003dinstance)"},{"line_number":6444,"context_line":""},{"line_number":6445,"context_line":"            time.sleep(0.5)"},{"line_number":6446,"context_line":"        try:"},{"line_number":6447,"context_line":"            del self.active_migrations[instance.uuid]"},{"line_number":6448,"context_line":"        except KeyError:"},{"line_number":6449,"context_line":"            LOG.warn(_LW(\"There are no records in \""}],"source_content_type":"text/x-python","patch_set":7,"id":"5a18252c_91e7f911","line":6446,"in_reply_to":"5a18252c_36889be7","updated":"2016-04-12 13:06:19.000000000","message":"okay, makes sense","commit_id":"2b927c679f4269a4ca280e45f6696a11fa7aa6ee"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"1ca35d5454d61e66733e38f37c017a3648e797a6","unresolved":false,"context_lines":[{"line_number":6443,"context_line":"                         info.type, instance\u003dinstance)"},{"line_number":6444,"context_line":""},{"line_number":6445,"context_line":"            time.sleep(0.5)"},{"line_number":6446,"context_line":"        try:"},{"line_number":6447,"context_line":"            del self.active_migrations[instance.uuid]"},{"line_number":6448,"context_line":"        except KeyError:"},{"line_number":6449,"context_line":"            LOG.warn(_LW(\"There are no records in \""}],"source_content_type":"text/x-python","patch_set":7,"id":"5a18252c_36889be7","line":6446,"in_reply_to":"5a18252c_ec35bdf7","updated":"2016-04-12 12:56:45.000000000","message":"Please check ps-5 for details, Roman proposed to change code this one, as it\u0027s atomic action instead of \nif a in dict:\n  ...","commit_id":"2b927c679f4269a4ca280e45f6696a11fa7aa6ee"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"46abd9465fb800e953773c28463b50681831fbd8","unresolved":false,"context_lines":[{"line_number":6523,"context_line":"        # NOTE(pkoniszewski): currently only pause during live migration is"},{"line_number":6524,"context_line":"        # supported to force live migration to complete, so just try to pause"},{"line_number":6525,"context_line":"        # the instance"},{"line_number":6526,"context_line":"        try:"},{"line_number":6527,"context_line":"            self.active_migrations[instance.uuid].append(\u0027pause\u0027)"},{"line_number":6528,"context_line":"        except KeyError:"},{"line_number":6529,"context_line":"            raise exception.NoActiveMigrationForInstance("}],"source_content_type":"text/x-python","patch_set":7,"id":"5a18252c_ecbaddbf","line":6526,"updated":"2016-04-12 09:54:30.000000000","message":"ditto","commit_id":"2b927c679f4269a4ca280e45f6696a11fa7aa6ee"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"6e6f0a0533e0775493ec22378d3feb92686b0233","unresolved":false,"context_lines":[{"line_number":6240,"context_line":"        progress_timeout \u003d CONF.libvirt.live_migration_progress_timeout"},{"line_number":6241,"context_line":"        migration \u003d migrate_data.migration"},{"line_number":6242,"context_line":""},{"line_number":6243,"context_line":"        def _check_scheduled_migration_task():"},{"line_number":6244,"context_line":"            tasks \u003d self.active_migrations.get(instance.uuid, deque())"},{"line_number":6245,"context_line":"            while tasks:"},{"line_number":6246,"context_line":"                task \u003d tasks.popleft()"}],"source_content_type":"text/x-python","patch_set":11,"id":"1a122d0e_070f46e2","line":6243,"range":{"start_line":6243,"start_character":8,"end_line":6243,"end_character":45},"updated":"2016-04-15 11:07:59.000000000","message":"the name of this method is too generic and doesn\u0027t reflect what the method does. Reading the code this method is a way to check and trigger a pause migration.\nIs that generic as we think to some future extension of this method?","commit_id":"c1550da469b7b3769f126438e5b16f4f36a0c994"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"e985e563e4a8b5c429fc84dd0aec8e3ee146c040","unresolved":false,"context_lines":[{"line_number":6240,"context_line":"        progress_timeout \u003d CONF.libvirt.live_migration_progress_timeout"},{"line_number":6241,"context_line":"        migration \u003d migrate_data.migration"},{"line_number":6242,"context_line":""},{"line_number":6243,"context_line":"        def _check_scheduled_migration_task():"},{"line_number":6244,"context_line":"            tasks \u003d self.active_migrations.get(instance.uuid, deque())"},{"line_number":6245,"context_line":"            while tasks:"},{"line_number":6246,"context_line":"                task \u003d tasks.popleft()"}],"source_content_type":"text/x-python","patch_set":11,"id":"1a122d0e_829344fa","line":6243,"range":{"start_line":6243,"start_character":8,"end_line":6243,"end_character":45},"in_reply_to":"1a122d0e_070f46e2","updated":"2016-04-15 15:10:42.000000000","message":"Yes, same method is used for handling live_migration_abort request.","commit_id":"c1550da469b7b3769f126438e5b16f4f36a0c994"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"6e6f0a0533e0775493ec22378d3feb92686b0233","unresolved":false,"context_lines":[{"line_number":6243,"context_line":"        def _check_scheduled_migration_task():"},{"line_number":6244,"context_line":"            tasks \u003d self.active_migrations.get(instance.uuid, deque())"},{"line_number":6245,"context_line":"            while tasks:"},{"line_number":6246,"context_line":"                task \u003d tasks.popleft()"},{"line_number":6247,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6248,"context_line":"                    try:"},{"line_number":6249,"context_line":"                        self.pause(instance)"}],"source_content_type":"text/x-python","patch_set":11,"id":"1a122d0e_a7cbf21d","line":6246,"range":{"start_line":6246,"start_character":15,"end_line":6246,"end_character":38},"updated":"2016-04-15 11:07:59.000000000","message":"I know that at the moment we put just \"pause\" in the deque but using pop we trow away the elements even if they are not what we are looking for. It seems more indicated here to use the deque.remove(\u0027pause\u0027) which remove the first occurrence of \u0027pause\u0027 and raise a ValueError if \u0027pause\u0027 is not found","commit_id":"c1550da469b7b3769f126438e5b16f4f36a0c994"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"e985e563e4a8b5c429fc84dd0aec8e3ee146c040","unresolved":false,"context_lines":[{"line_number":6243,"context_line":"        def _check_scheduled_migration_task():"},{"line_number":6244,"context_line":"            tasks \u003d self.active_migrations.get(instance.uuid, deque())"},{"line_number":6245,"context_line":"            while tasks:"},{"line_number":6246,"context_line":"                task \u003d tasks.popleft()"},{"line_number":6247,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6248,"context_line":"                    try:"},{"line_number":6249,"context_line":"                        self.pause(instance)"}],"source_content_type":"text/x-python","patch_set":11,"id":"1a122d0e_e2a3184e","line":6246,"range":{"start_line":6246,"start_character":15,"end_line":6246,"end_character":38},"in_reply_to":"1a122d0e_a7cbf21d","updated":"2016-04-15 15:10:42.000000000","message":"It\u0027s supposed to be generic method, for such tasks, check for example subsequent patch, abort operation added here also. So it would be wrong to use remove(\u0027pause\u0027) here","commit_id":"c1550da469b7b3769f126438e5b16f4f36a0c994"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"6e6f0a0533e0775493ec22378d3feb92686b0233","unresolved":false,"context_lines":[{"line_number":6312,"context_line":"                # This is where we wire up calls to change live"},{"line_number":6313,"context_line":"                # migration status. eg change max downtime, cancel"},{"line_number":6314,"context_line":"                # the operation, change max bandwidth"},{"line_number":6315,"context_line":"                _check_scheduled_migration_task()"},{"line_number":6316,"context_line":"                now \u003d time.time()"},{"line_number":6317,"context_line":"                elapsed \u003d now - start"},{"line_number":6318,"context_line":"                abort \u003d False"}],"source_content_type":"text/x-python","patch_set":11,"id":"1a122d0e_c7cf0eb2","line":6315,"range":{"start_line":6315,"start_character":16,"end_line":6315,"end_character":49},"updated":"2016-04-15 11:07:59.000000000","message":"is it correct to try to pause the migration here? It seems more correct to check if we want to abort the migration first and we don\u0027t abort it (abort\u003dfalse after all the progress checks) then we check if we have a pending \"pause\" command","commit_id":"c1550da469b7b3769f126438e5b16f4f36a0c994"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"e985e563e4a8b5c429fc84dd0aec8e3ee146c040","unresolved":false,"context_lines":[{"line_number":6312,"context_line":"                # This is where we wire up calls to change live"},{"line_number":6313,"context_line":"                # migration status. eg change max downtime, cancel"},{"line_number":6314,"context_line":"                # the operation, change max bandwidth"},{"line_number":6315,"context_line":"                _check_scheduled_migration_task()"},{"line_number":6316,"context_line":"                now \u003d time.time()"},{"line_number":6317,"context_line":"                elapsed \u003d now - start"},{"line_number":6318,"context_line":"                abort \u003d False"}],"source_content_type":"text/x-python","patch_set":11,"id":"1a122d0e_ad9f51b3","line":6315,"range":{"start_line":6315,"start_character":16,"end_line":6315,"end_character":49},"in_reply_to":"1a122d0e_c7cf0eb2","updated":"2016-04-15 15:10:42.000000000","message":"I think it\u0027s actually not important, where to handle tasks, there is still room to leave instance paused in case of failure. In the next patches this problem fixed.","commit_id":"c1550da469b7b3769f126438e5b16f4f36a0c994"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"cbb349bbf0d353754a40754d4f62b69aece18453","unresolved":false,"context_lines":[{"line_number":6446,"context_line":"                # Migration did not succeed"},{"line_number":6447,"context_line":"                LOG.error(_LE(\"Migration operation has aborted\"),"},{"line_number":6448,"context_line":"                          instance\u003dinstance)"},{"line_number":6449,"context_line":"                _recover_scheduled_migration_task()"},{"line_number":6450,"context_line":"                recover_method(context, instance, dest, block_migration,"},{"line_number":6451,"context_line":"                               migrate_data)"},{"line_number":6452,"context_line":"                break"}],"source_content_type":"text/x-python","patch_set":12,"id":"1a122d0e_c9c31388","line":6449,"updated":"2016-04-19 16:42:27.000000000","message":"Hmm, this is an extra bug fix you might want to mention in the git commit message.","commit_id":"916947b09f9f946734551e137dce84d52cefda3f"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"09ad5ac2280c274c9d76f78e83b7487123f031f0","unresolved":false,"context_lines":[{"line_number":6446,"context_line":"                # Migration did not succeed"},{"line_number":6447,"context_line":"                LOG.error(_LE(\"Migration operation has aborted\"),"},{"line_number":6448,"context_line":"                          instance\u003dinstance)"},{"line_number":6449,"context_line":"                _recover_scheduled_migration_task()"},{"line_number":6450,"context_line":"                recover_method(context, instance, dest, block_migration,"},{"line_number":6451,"context_line":"                               migrate_data)"},{"line_number":6452,"context_line":"                break"}],"source_content_type":"text/x-python","patch_set":12,"id":"1a122d0e_8550ae0c","line":6449,"in_reply_to":"1a122d0e_c9c31388","updated":"2016-04-20 13:45:02.000000000","message":"Done","commit_id":"916947b09f9f946734551e137dce84d52cefda3f"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"f39de9e52a6f5c8fd2b691e04e93f75d99eef9b3","unresolved":false,"context_lines":[{"line_number":6258,"context_line":"        progress_timeout \u003d CONF.libvirt.live_migration_progress_timeout"},{"line_number":6259,"context_line":"        migration \u003d migrate_data.migration"},{"line_number":6260,"context_line":""},{"line_number":6261,"context_line":"        def _check_scheduled_migration_task():"},{"line_number":6262,"context_line":"            tasks \u003d self.active_migrations.get(instance.uuid, deque())"},{"line_number":6263,"context_line":"            while tasks:"},{"line_number":6264,"context_line":"                task \u003d tasks.popleft()"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a122d0e_2c2ff53f","line":6261,"updated":"2016-04-20 17:04:19.000000000","message":"You\u0027ll probably avoid the pep8 failure in the next patch if you move these methods out so they\u0027re not embedded in _live_migration_monitor.","commit_id":"78ab94bee4cebb7655fd82fe2a68f130935091cc"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"33f1dd73ae2973d29ed7e1228fd84287021c32c4","unresolved":false,"context_lines":[{"line_number":6258,"context_line":"        progress_timeout \u003d CONF.libvirt.live_migration_progress_timeout"},{"line_number":6259,"context_line":"        migration \u003d migrate_data.migration"},{"line_number":6260,"context_line":""},{"line_number":6261,"context_line":"        def _check_scheduled_migration_task():"},{"line_number":6262,"context_line":"            tasks \u003d self.active_migrations.get(instance.uuid, deque())"},{"line_number":6263,"context_line":"            while tasks:"},{"line_number":6264,"context_line":"                task \u003d tasks.popleft()"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a122d0e_4c3d11dc","line":6261,"in_reply_to":"1a122d0e_2c2ff53f","updated":"2016-04-20 17:09:01.000000000","message":"tbh I want to move live_migration_monitor itself out to it\u0027s own module/class. For now I think it\u0027s worth to merge this patch first - than move monitor, and than build path for abort live-migration on top of it.","commit_id":"78ab94bee4cebb7655fd82fe2a68f130935091cc"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"bc810bad2783a4e9d33f695efb77fcd08bd12e0d","unresolved":false,"context_lines":[{"line_number":6258,"context_line":"        progress_timeout \u003d CONF.libvirt.live_migration_progress_timeout"},{"line_number":6259,"context_line":"        migration \u003d migrate_data.migration"},{"line_number":6260,"context_line":""},{"line_number":6261,"context_line":"        def _check_scheduled_migration_task():"},{"line_number":6262,"context_line":"            tasks \u003d self.active_migrations.get(instance.uuid, deque())"},{"line_number":6263,"context_line":"            while tasks:"},{"line_number":6264,"context_line":"                task \u003d tasks.popleft()"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a122d0e_c66bbd1c","line":6261,"in_reply_to":"1a122d0e_4c3d11dc","updated":"2016-04-20 17:58:35.000000000","message":"Sure, that is reasonable. As long as you can appease the complexity test in pep8 :)","commit_id":"78ab94bee4cebb7655fd82fe2a68f130935091cc"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"f39de9e52a6f5c8fd2b691e04e93f75d99eef9b3","unresolved":false,"context_lines":[{"line_number":6265,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6266,"context_line":"                    try:"},{"line_number":6267,"context_line":"                        self.pause(instance)"},{"line_number":6268,"context_line":"                        on_migration_failure.append(\"pause\")"},{"line_number":6269,"context_line":"                    except Exception as e:"},{"line_number":6270,"context_line":"                        LOG.warning(_LW(\"Failed to pause instance during \""},{"line_number":6271,"context_line":"                                        \"live-migration %s\"),"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a122d0e_ec769d04","line":6268,"updated":"2016-04-20 17:04:19.000000000","message":"This should probably be \"unpause\".","commit_id":"78ab94bee4cebb7655fd82fe2a68f130935091cc"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"274854fc3131b0c09ff0c09c4e842d37c4d30e7d","unresolved":false,"context_lines":[{"line_number":6265,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6266,"context_line":"                    try:"},{"line_number":6267,"context_line":"                        self.pause(instance)"},{"line_number":6268,"context_line":"                        on_migration_failure.append(\"pause\")"},{"line_number":6269,"context_line":"                    except Exception as e:"},{"line_number":6270,"context_line":"                        LOG.warning(_LW(\"Failed to pause instance during \""},{"line_number":6271,"context_line":"                                        \"live-migration %s\"),"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a122d0e_57a11a45","line":6268,"in_reply_to":"1a122d0e_ec769d04","updated":"2016-04-20 17:22:46.000000000","message":"Done","commit_id":"78ab94bee4cebb7655fd82fe2a68f130935091cc"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"f39de9e52a6f5c8fd2b691e04e93f75d99eef9b3","unresolved":false,"context_lines":[{"line_number":6274,"context_line":"        def _recover_scheduled_migration_task():"},{"line_number":6275,"context_line":"            while on_migration_failure:"},{"line_number":6276,"context_line":"                task \u003d on_migration_failure.popleft()"},{"line_number":6277,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6278,"context_line":"                    try:"},{"line_number":6279,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6280,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a122d0e_2c637543","line":6277,"updated":"2016-04-20 17:04:19.000000000","message":"\"unpause\" would be better I think.","commit_id":"78ab94bee4cebb7655fd82fe2a68f130935091cc"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"274854fc3131b0c09ff0c09c4e842d37c4d30e7d","unresolved":false,"context_lines":[{"line_number":6274,"context_line":"        def _recover_scheduled_migration_task():"},{"line_number":6275,"context_line":"            while on_migration_failure:"},{"line_number":6276,"context_line":"                task \u003d on_migration_failure.popleft()"},{"line_number":6277,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6278,"context_line":"                    try:"},{"line_number":6279,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6280,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a122d0e_978732b4","line":6277,"in_reply_to":"1a122d0e_2c637543","updated":"2016-04-20 17:22:46.000000000","message":"Done","commit_id":"78ab94bee4cebb7655fd82fe2a68f130935091cc"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"06f4de4f5d40394a6019ded86dff4f631ac42538","unresolved":false,"context_lines":[{"line_number":6245,"context_line":""},{"line_number":6246,"context_line":"        return ram_gb + disk_gb"},{"line_number":6247,"context_line":""},{"line_number":6248,"context_line":"    def _live_migration_monitor(self, context, instance, guest,"},{"line_number":6249,"context_line":"                                dest, post_method,"},{"line_number":6250,"context_line":"                                recover_method, block_migration,"},{"line_number":6251,"context_line":"                                migrate_data, dom, finish_event,"}],"source_content_type":"text/x-python","patch_set":15,"id":"1a122d0e_49e33ed9","line":6248,"updated":"2016-04-20 18:54:44.000000000","message":"This is getting huge. I won\u0027t complain here, but I think that we should start thinking about moving all live migration stuff to new file","commit_id":"ff4e1f5bc613b5869609cd9632b8a1fc5832cf07"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"daa79ec89998a7ff5173c5cab8dcbc76a788e1fd","unresolved":false,"context_lines":[{"line_number":6245,"context_line":""},{"line_number":6246,"context_line":"        return ram_gb + disk_gb"},{"line_number":6247,"context_line":""},{"line_number":6248,"context_line":"    def _live_migration_monitor(self, context, instance, guest,"},{"line_number":6249,"context_line":"                                dest, post_method,"},{"line_number":6250,"context_line":"                                recover_method, block_migration,"},{"line_number":6251,"context_line":"                                migrate_data, dom, finish_event,"}],"source_content_type":"text/x-python","patch_set":15,"id":"1a122d0e_dad1ca24","line":6248,"in_reply_to":"1a122d0e_49e33ed9","updated":"2016-04-20 19:25:54.000000000","message":"Agree, please check comments for previous ps, this is exactly what I\u0027m going to do with monitor","commit_id":"ff4e1f5bc613b5869609cd9632b8a1fc5832cf07"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"06f4de4f5d40394a6019ded86dff4f631ac42538","unresolved":false,"context_lines":[{"line_number":6274,"context_line":"        def _recover_scheduled_migration_task():"},{"line_number":6275,"context_line":"            while on_migration_failure:"},{"line_number":6276,"context_line":"                task \u003d on_migration_failure.popleft()"},{"line_number":6277,"context_line":"                if task \u003d\u003d \u0027unpause\u0027:"},{"line_number":6278,"context_line":"                    try:"},{"line_number":6279,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6280,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":15,"id":"1a122d0e_dc0f0a35","line":6277,"updated":"2016-04-20 18:54:44.000000000","message":"Why do we need to perform this operation? Libvirt will always revert VM state and we don\u0027t change VM state in nova internally when doing force complete. If this is a corner case then we need a comment here explaining why we need this there. Otherwise someone might try to \u0027fix it\u0027, because, well, libvirt reverts VM\u0027s power state.","commit_id":"ff4e1f5bc613b5869609cd9632b8a1fc5832cf07"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"daa79ec89998a7ff5173c5cab8dcbc76a788e1fd","unresolved":false,"context_lines":[{"line_number":6274,"context_line":"        def _recover_scheduled_migration_task():"},{"line_number":6275,"context_line":"            while on_migration_failure:"},{"line_number":6276,"context_line":"                task \u003d on_migration_failure.popleft()"},{"line_number":6277,"context_line":"                if task \u003d\u003d \u0027unpause\u0027:"},{"line_number":6278,"context_line":"                    try:"},{"line_number":6279,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6280,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":15,"id":"1a122d0e_5abdbad6","line":6277,"in_reply_to":"1a122d0e_dc0f0a35","updated":"2016-04-20 19:25:54.000000000","message":"If live-migration for example aborted or failed after vm paused libvirt won\u0027t resume vm, so it\u0027s left paused on source node. \u0027Unpause\u0027 was added to mitigate this possibility. Not sure that someone will remove method without checking it before, will add note for this to make it explicitly clear.","commit_id":"ff4e1f5bc613b5869609cd9632b8a1fc5832cf07"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"ce79e22c33853db932c6579e18c8978541b13ef8","unresolved":false,"context_lines":[{"line_number":6278,"context_line":"                # instance paused in case of live-migration failure."},{"line_number":6279,"context_line":"                # This check guarantee that instance will be resumed"},{"line_number":6280,"context_line":"                # in this case"},{"line_number":6281,"context_line":"                if task \u003d\u003d \u0027unpause\u0027:"},{"line_number":6282,"context_line":"                    try:"},{"line_number":6283,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6284,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a122d0e_7a6fd6fb","line":6281,"updated":"2016-04-20 19:33:14.000000000","message":"Going back with my comment. I just tested it and it reverts task state for me. Even if I kill nova-compute and abort through libvirt it puts VM back into active state.\n\nSo can you write here which version of libvirt do you use? I\u0027d like to be able to confirm it.","commit_id":"d107089c79fd878a481cb1c8ecce4a79c0d572e5"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"403ef9f0b0166205354ed2e74812a6f5da2a82d8","unresolved":false,"context_lines":[{"line_number":6278,"context_line":"                # instance paused in case of live-migration failure."},{"line_number":6279,"context_line":"                # This check guarantee that instance will be resumed"},{"line_number":6280,"context_line":"                # in this case"},{"line_number":6281,"context_line":"                if task \u003d\u003d \u0027unpause\u0027:"},{"line_number":6282,"context_line":"                    try:"},{"line_number":6283,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6284,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a122d0e_db2ed541","line":6281,"in_reply_to":"1a122d0e_7a6fd6fb","updated":"2016-04-21 08:50:05.000000000","message":"Pawel, I believe it\u0027s not libvirt issue, as it dumps state prior to l-m and then reverts it in case of failure. So the only possibility that force_live_migration pause vm before nova actually call migrateToURI. And this is possible, check lines from 6299 to 6316. From my sight, it\u0027s better to double check instance state, to be sure that we don\u0027t leave instance paused.","commit_id":"d107089c79fd878a481cb1c8ecce4a79c0d572e5"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"041b82c6b03903ae750c0d632807beaf06e41b07","unresolved":false,"context_lines":[{"line_number":6278,"context_line":"                # instance paused in case of live-migration failure."},{"line_number":6279,"context_line":"                # This check guarantee that instance will be resumed"},{"line_number":6280,"context_line":"                # in this case"},{"line_number":6281,"context_line":"                if task \u003d\u003d \u0027unpause\u0027:"},{"line_number":6282,"context_line":"                    try:"},{"line_number":6283,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6284,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a122d0e_452aade8","line":6281,"in_reply_to":"1a122d0e_88cd1989","updated":"2016-04-22 09:44:00.000000000","message":"Agree about, potential issue with pausing instance on dest node. At the same time I think it\u0027s ok to recheck instance status on destination node in case of failure.","commit_id":"d107089c79fd878a481cb1c8ecce4a79c0d572e5"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"cb30cfaadb2098c1553bb3ef5949ec70e274566c","unresolved":false,"context_lines":[{"line_number":6278,"context_line":"                # instance paused in case of live-migration failure."},{"line_number":6279,"context_line":"                # This check guarantee that instance will be resumed"},{"line_number":6280,"context_line":"                # in this case"},{"line_number":6281,"context_line":"                if task \u003d\u003d \u0027unpause\u0027:"},{"line_number":6282,"context_line":"                    try:"},{"line_number":6283,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6284,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a122d0e_88cd1989","line":6281,"in_reply_to":"1a122d0e_db2ed541","updated":"2016-04-21 16:25:47.000000000","message":"Okay, so this might be even worse. Line 6302 says that migration might not yet begun. If we pause VM prior to migration start, we will only unpause it in case of failure, but in case of a success we will end up with VM paused on destination.","commit_id":"d107089c79fd878a481cb1c8ecce4a79c0d572e5"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"cb30cfaadb2098c1553bb3ef5949ec70e274566c","unresolved":false,"context_lines":[{"line_number":6299,"context_line":"                # Annoyingly this could indicate many possible"},{"line_number":6300,"context_line":"                # states, so we must fix the mess:"},{"line_number":6301,"context_line":"                #"},{"line_number":6302,"context_line":"                #   1. Migration has not yet begun"},{"line_number":6303,"context_line":"                #   2. Migration has stopped due to failure"},{"line_number":6304,"context_line":"                #   3. Migration has stopped due to completion"},{"line_number":6305,"context_line":"                #"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a122d0e_68787d2c","line":6302,"updated":"2016-04-21 16:25:47.000000000","message":"Given this comment is correct I think that line 6313 should be removed. We don\u0027t want to force migration to complete prior to migration start (it\u0027s pointless, isn\u0027t it?)","commit_id":"d107089c79fd878a481cb1c8ecce4a79c0d572e5"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"041b82c6b03903ae750c0d632807beaf06e41b07","unresolved":false,"context_lines":[{"line_number":6299,"context_line":"                # Annoyingly this could indicate many possible"},{"line_number":6300,"context_line":"                # states, so we must fix the mess:"},{"line_number":6301,"context_line":"                #"},{"line_number":6302,"context_line":"                #   1. Migration has not yet begun"},{"line_number":6303,"context_line":"                #   2. Migration has stopped due to failure"},{"line_number":6304,"context_line":"                #   3. Migration has stopped due to completion"},{"line_number":6305,"context_line":"                #"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a122d0e_a547411c","line":6302,"in_reply_to":"1a122d0e_68787d2c","updated":"2016-04-22 09:44:00.000000000","message":"Yes, removed line 6313.","commit_id":"d107089c79fd878a481cb1c8ecce4a79c0d572e5"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"01d42d87d19142d976517b591ebfb79d821ad38b","unresolved":false,"context_lines":[{"line_number":6310,"context_line":"                if not finish_event.ready():"},{"line_number":6311,"context_line":"                    LOG.debug(\"Operation thread is still running\","},{"line_number":6312,"context_line":"                              instance\u003dinstance)"},{"line_number":6313,"context_line":"                    _check_scheduled_migration_task()"},{"line_number":6314,"context_line":"                    # Leave type untouched"},{"line_number":6315,"context_line":"                else:"},{"line_number":6316,"context_line":"                    try:"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a122d0e_aed73dec","line":6313,"updated":"2016-04-21 17:03:29.000000000","message":"What\u0027s more, if migration has stopped due to completion and we try to pause an instance that is not on this host anymore, we will end up with an exception here, therefore not really running post live migration operations.","commit_id":"d107089c79fd878a481cb1c8ecce4a79c0d572e5"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"2b435b7050cb2a53b85fe948dbe848cfe9058f12","unresolved":false,"context_lines":[{"line_number":6310,"context_line":"                if not finish_event.ready():"},{"line_number":6311,"context_line":"                    LOG.debug(\"Operation thread is still running\","},{"line_number":6312,"context_line":"                              instance\u003dinstance)"},{"line_number":6313,"context_line":"                    _check_scheduled_migration_task()"},{"line_number":6314,"context_line":"                    # Leave type untouched"},{"line_number":6315,"context_line":"                else:"},{"line_number":6316,"context_line":"                    try:"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a122d0e_5992b1a0","line":6313,"in_reply_to":"1a122d0e_aed73dec","updated":"2016-04-21 17:13:14.000000000","message":"Oh, sorry, this will not break, but still, at this point we are not sure what\u0027s happening with migration so we shouldn\u0027t try to change it any way.","commit_id":"d107089c79fd878a481cb1c8ecce4a79c0d572e5"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"c79fbe4ae531a07f6e98b6f3d0586038501696e3","unresolved":false,"context_lines":[{"line_number":6287,"context_line":"        def _check_scheduled_migration_task():"},{"line_number":6288,"context_line":"            tasks \u003d self.active_migrations.get(instance.uuid, deque())"},{"line_number":6289,"context_line":"            while tasks:"},{"line_number":6290,"context_line":"                task \u003d tasks.popleft()"},{"line_number":6291,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6292,"context_line":"                    try:"},{"line_number":6293,"context_line":"                        self.pause(instance)"}],"source_content_type":"text/x-python","patch_set":17,"id":"1a122d0e_e14c7a9f","line":6290,"range":{"start_line":6290,"start_character":15,"end_line":6290,"end_character":38},"updated":"2016-04-22 15:50:57.000000000","message":"I am still not fully convinced that the pop is the right thing to do here, what about a loop for getting what we are looking for and then remove just that task?","commit_id":"225881a72eeb7c66e4f0c5f7891437715a612f3a"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"d1d18b9614d3f1adf0c454a73b6b3b5ed7fd075c","unresolved":false,"context_lines":[{"line_number":6287,"context_line":"        def _check_scheduled_migration_task():"},{"line_number":6288,"context_line":"            tasks \u003d self.active_migrations.get(instance.uuid, deque())"},{"line_number":6289,"context_line":"            while tasks:"},{"line_number":6290,"context_line":"                task \u003d tasks.popleft()"},{"line_number":6291,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6292,"context_line":"                    try:"},{"line_number":6293,"context_line":"                        self.pause(instance)"}],"source_content_type":"text/x-python","patch_set":17,"id":"1a122d0e_8d74ac9c","line":6290,"range":{"start_line":6290,"start_character":15,"end_line":6290,"end_character":38},"in_reply_to":"1a122d0e_e14c7a9f","updated":"2016-04-25 10:20:00.000000000","message":"Not sure why will operator decide to send several same requests to nova. At the same time I believe there are no reasons to prevent nova to execute these requests. I think tasks here are kind of conveyor, which handles all requests passed in.","commit_id":"225881a72eeb7c66e4f0c5f7891437715a612f3a"},{"author":{"_account_id":1865,"name":"Andrea Rosa","email":"andrea.rosa@gmail.com","username":"andrea-rosa-m"},"change_message_id":"c79fbe4ae531a07f6e98b6f3d0586038501696e3","unresolved":false,"context_lines":[{"line_number":6291,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6292,"context_line":"                    try:"},{"line_number":6293,"context_line":"                        self.pause(instance)"},{"line_number":6294,"context_line":"                        on_migration_failure.append(\"unpause\")"},{"line_number":6295,"context_line":"                    except Exception as e:"},{"line_number":6296,"context_line":"                        LOG.warning(_LW(\"Failed to pause instance during \""},{"line_number":6297,"context_line":"                                        \"live-migration %s\"),"}],"source_content_type":"text/x-python","patch_set":17,"id":"1a122d0e_c41d0c68","line":6294,"updated":"2016-04-22 15:50:57.000000000","message":"if we have more than one pause request and the first one goes well I think we should remove all the other pending pause requests and exit the loop.","commit_id":"225881a72eeb7c66e4f0c5f7891437715a612f3a"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"d1d18b9614d3f1adf0c454a73b6b3b5ed7fd075c","unresolved":false,"context_lines":[{"line_number":6291,"context_line":"                if task \u003d\u003d \u0027pause\u0027:"},{"line_number":6292,"context_line":"                    try:"},{"line_number":6293,"context_line":"                        self.pause(instance)"},{"line_number":6294,"context_line":"                        on_migration_failure.append(\"unpause\")"},{"line_number":6295,"context_line":"                    except Exception as e:"},{"line_number":6296,"context_line":"                        LOG.warning(_LW(\"Failed to pause instance during \""},{"line_number":6297,"context_line":"                                        \"live-migration %s\"),"}],"source_content_type":"text/x-python","patch_set":17,"id":"1a122d0e_92ee8989","line":6294,"in_reply_to":"1a122d0e_c41d0c68","updated":"2016-04-25 10:20:00.000000000","message":"I think it\u0027s should be on operator side not to pass several force requests to Nova.","commit_id":"225881a72eeb7c66e4f0c5f7891437715a612f3a"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"8ea26e7809960290df596b92d7dde6bf819b68aa","unresolved":false,"context_lines":[{"line_number":6300,"context_line":"        def _recover_scheduled_migration_task():"},{"line_number":6301,"context_line":"            while on_migration_failure:"},{"line_number":6302,"context_line":"                task \u003d on_migration_failure.popleft()"},{"line_number":6303,"context_line":"                if task \u003d\u003d \u0027unpause\u0027:"},{"line_number":6304,"context_line":"                    try:"},{"line_number":6305,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6306,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":17,"id":"1a122d0e_81266614","line":6303,"updated":"2016-04-22 15:44:03.000000000","message":"Can you please restore a comment here? For new people this method might indicate that nova is restoring VM state when LM fails/is aborted. It needs to be clear that libvirt restores VM state, but here we try to handle something that really should not happen.","commit_id":"225881a72eeb7c66e4f0c5f7891437715a612f3a"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"d1d18b9614d3f1adf0c454a73b6b3b5ed7fd075c","unresolved":false,"context_lines":[{"line_number":6300,"context_line":"        def _recover_scheduled_migration_task():"},{"line_number":6301,"context_line":"            while on_migration_failure:"},{"line_number":6302,"context_line":"                task \u003d on_migration_failure.popleft()"},{"line_number":6303,"context_line":"                if task \u003d\u003d \u0027unpause\u0027:"},{"line_number":6304,"context_line":"                    try:"},{"line_number":6305,"context_line":"                        state \u003d guest.get_power_state(self._host)"},{"line_number":6306,"context_line":"                        if state \u003d\u003d power_state.PAUSED:"}],"source_content_type":"text/x-python","patch_set":17,"id":"1a122d0e_f23a5d33","line":6303,"in_reply_to":"1a122d0e_81266614","updated":"2016-04-25 10:20:00.000000000","message":"Done","commit_id":"225881a72eeb7c66e4f0c5f7891437715a612f3a"},{"author":{"_account_id":12299,"name":"Paweł Koniszewski","email":"pawel.koniszewski@gmail.com","username":"pawel.koniszewski"},"change_message_id":"8ea26e7809960290df596b92d7dde6bf819b68aa","unresolved":false,"context_lines":[{"line_number":6307,"context_line":"                            guest.resume()"},{"line_number":6308,"context_line":"                    except Exception as e:"},{"line_number":6309,"context_line":"                        LOG.warning(_LW(\"Failed to resume paused instance \""},{"line_number":6310,"context_line":"                                        \"after live-migration failure %s\"),"},{"line_number":6311,"context_line":"                                    e, instance\u003dinstance)"},{"line_number":6312,"context_line":""},{"line_number":6313,"context_line":"        n \u003d 0"}],"source_content_type":"text/x-python","patch_set":17,"id":"1a122d0e_c16cde9e","line":6310,"range":{"start_line":6310,"start_character":62,"end_line":6310,"end_character":69},"updated":"2016-04-22 15:44:03.000000000","message":"Sorry I didn\u0027t catch it in previous patch set. We shouldn\u0027t use this word here, because we allow to abort live migration which is not a failure. If operator aborts LM we will throw warning message saying that live migration failed which is not true in such case.","commit_id":"225881a72eeb7c66e4f0c5f7891437715a612f3a"},{"author":{"_account_id":14819,"name":"Timofey Durakov","email":"timofei.nd@gmail.com","username":"tdurakov"},"change_message_id":"d1d18b9614d3f1adf0c454a73b6b3b5ed7fd075c","unresolved":false,"context_lines":[{"line_number":6307,"context_line":"                            guest.resume()"},{"line_number":6308,"context_line":"                    except Exception as e:"},{"line_number":6309,"context_line":"                        LOG.warning(_LW(\"Failed to resume paused instance \""},{"line_number":6310,"context_line":"                                        \"after live-migration failure %s\"),"},{"line_number":6311,"context_line":"                                    e, instance\u003dinstance)"},{"line_number":6312,"context_line":""},{"line_number":6313,"context_line":"        n \u003d 0"}],"source_content_type":"text/x-python","patch_set":17,"id":"1a122d0e_b2d465bd","line":6310,"range":{"start_line":6310,"start_character":62,"end_line":6310,"end_character":69},"in_reply_to":"1a122d0e_c16cde9e","updated":"2016-04-25 10:20:00.000000000","message":"Done","commit_id":"225881a72eeb7c66e4f0c5f7891437715a612f3a"}]}
