)]}'
{"nova/compute/api.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"79d971ab4bad12aa1ce1bfe6e73b71fc17f00c51","unresolved":false,"context_lines":[{"line_number":3506,"context_line":"            else:"},{"line_number":3507,"context_line":"                # Set the host and the node so that the scheduler will"},{"line_number":3508,"context_line":"                # validate them."},{"line_number":3509,"context_line":"                # TODO(takashin): It will be added to check whether"},{"line_number":3510,"context_line":"                # the specified host is within the same cell as"},{"line_number":3511,"context_line":"                # the instance or not. If not, raise specific error message"},{"line_number":3512,"context_line":"                # that is clear to the caller."}],"source_content_type":"text/x-python","patch_set":1,"id":"3f79a3b5_d8ca626c","side":"PARENT","line":3509,"updated":"2018-09-19 23:44:35.000000000","message":"Rebase on top of https://review.openstack.org/#/c/603924.","commit_id":"13eccbdf90eaf6d9b760f6b75471c1f269acb7bf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"5d6fcd896d5015b36b9077fc392b8c6da407ae52","unresolved":false,"context_lines":[{"line_number":3482,"context_line":""},{"line_number":3483,"context_line":"        # TODO(mriedem): Call instance.drop_migration_context()?"},{"line_number":3484,"context_line":""},{"line_number":3485,"context_line":"        # NOTE(mriedem): The old_vm_state could be STOPPED but the user"},{"line_number":3486,"context_line":"        # might have manually powered up the instance to confirm the"},{"line_number":3487,"context_line":"        # resize/migrate, so we need to check the current power state"},{"line_number":3488,"context_line":"        # on the instance and set the vm_state appropriately. We default"},{"line_number":3489,"context_line":"        # to ACTIVE because if the power state is not SHUTDOWN, we"},{"line_number":3490,"context_line":"        # assume _sync_instance_power_state will clean it up."},{"line_number":3491,"context_line":"        p_state \u003d instance.power_state"},{"line_number":3492,"context_line":"        if p_state \u003d\u003d power_state.SHUTDOWN:"},{"line_number":3493,"context_line":"            vm_state \u003d vm_states.STOPPED"},{"line_number":3494,"context_line":"            LOG.debug(\"Resized/migrated instance is powered off. \""},{"line_number":3495,"context_line":"                      \"Setting vm_state to \u0027%s\u0027.\", vm_state,"},{"line_number":3496,"context_line":"                      instance\u003dinstance)"},{"line_number":3497,"context_line":"        else:"},{"line_number":3498,"context_line":"            vm_state \u003d vm_states.ACTIVE"},{"line_number":3499,"context_line":""},{"line_number":3500,"context_line":"        instance.vm_state \u003d vm_state"},{"line_number":3501,"context_line":"        instance.task_state \u003d None"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_71259dbf","line":3498,"range":{"start_line":3485,"start_character":8,"end_line":3498,"end_character":39},"updated":"2018-11-07 00:34:21.000000000","message":"Wouldn\u0027t we actually need to stop the instance on the dest host if that is the case?","commit_id":"f5a04460e490835611aab979d11bad2298f668f8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"9f1bf9142df003e7905bced6a593fd69b47212b7","unresolved":false,"context_lines":[{"line_number":3482,"context_line":""},{"line_number":3483,"context_line":"        # TODO(mriedem): Call instance.drop_migration_context()?"},{"line_number":3484,"context_line":""},{"line_number":3485,"context_line":"        # NOTE(mriedem): The old_vm_state could be STOPPED but the user"},{"line_number":3486,"context_line":"        # might have manually powered up the instance to confirm the"},{"line_number":3487,"context_line":"        # resize/migrate, so we need to check the current power state"},{"line_number":3488,"context_line":"        # on the instance and set the vm_state appropriately. We default"},{"line_number":3489,"context_line":"        # to ACTIVE because if the power state is not SHUTDOWN, we"},{"line_number":3490,"context_line":"        # assume _sync_instance_power_state will clean it up."},{"line_number":3491,"context_line":"        p_state \u003d instance.power_state"},{"line_number":3492,"context_line":"        if p_state \u003d\u003d power_state.SHUTDOWN:"},{"line_number":3493,"context_line":"            vm_state \u003d vm_states.STOPPED"},{"line_number":3494,"context_line":"            LOG.debug(\"Resized/migrated instance is powered off. \""},{"line_number":3495,"context_line":"                      \"Setting vm_state to \u0027%s\u0027.\", vm_state,"},{"line_number":3496,"context_line":"                      instance\u003dinstance)"},{"line_number":3497,"context_line":"        else:"},{"line_number":3498,"context_line":"            vm_state \u003d vm_states.ACTIVE"},{"line_number":3499,"context_line":""},{"line_number":3500,"context_line":"        instance.vm_state \u003d vm_state"},{"line_number":3501,"context_line":"        instance.task_state \u003d None"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_8a09db34","line":3498,"range":{"start_line":3485,"start_character":8,"end_line":3498,"end_character":39},"in_reply_to":"3f79a3b5_71259dbf","updated":"2018-12-10 22:42:25.000000000","message":"Adding a TODO to investigate this.","commit_id":"f5a04460e490835611aab979d11bad2298f668f8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"0d22f6d17602043cba9ae807e5b7c583787e1f5b","unresolved":false,"context_lines":[{"line_number":4715,"context_line":"            if migration.uuid not in migrations_by_uuid:"},{"line_number":4716,"context_line":"                migrations_by_uuid[migration.uuid] \u003d migration"},{"line_number":4717,"context_line":"            else:"},{"line_number":4718,"context_line":"                # We have a collision, keep the one with the later updated_at."},{"line_number":4719,"context_line":"                doppleganger \u003d migrations_by_uuid[migration.uuid]"},{"line_number":4720,"context_line":"                old_updated_at \u003d doppleganger.updated_at"},{"line_number":4721,"context_line":"                new_updated_at \u003d migration.updated_at"}],"source_content_type":"text/x-python","patch_set":20,"id":"bfdaf3ff_b60ee28a","line":4718,"range":{"start_line":4718,"start_character":61,"end_line":4718,"end_character":77},"updated":"2019-01-16 20:11:19.000000000","message":"This could be wrong if changes-since or changes-before filters are being used...","commit_id":"bc79de13d4e314a00c6c9789d6ce503c9ef13fd7"}],"nova/compute/manager.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1828c8b5d1172a761574ba0408712e528e9e42cd","unresolved":false,"context_lines":[{"line_number":5151,"context_line":"        compute_utils.remove_shelved_keys_from_system_metadata(instance)"},{"line_number":5152,"context_line":""},{"line_number":5153,"context_line":"        instance.save(expected_task_state\u003dtask_states.SPAWNING)"},{"line_number":5154,"context_line":"        if migration:"},{"line_number":5155,"context_line":"            migration.status \u003d \u0027finished\u0027"},{"line_number":5156,"context_line":"            migration.save()"},{"line_number":5157,"context_line":"        self._update_scheduler_instance_info(context, instance)"}],"source_content_type":"text/x-python","patch_set":3,"id":"3f79a3b5_ca90de99","line":5154,"updated":"2018-09-25 21:11:14.000000000","message":"Could use _set_migration_status here.","commit_id":"ed7175dd98f0afc4c42cb146512a52a6459759bd"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fc7d61fe85fc209b6a6d47516b65ad4947f1cf64","unresolved":false,"context_lines":[{"line_number":5136,"context_line":"        network_info \u003d self.network_api.get_instance_nw_info(context, instance)"},{"line_number":5137,"context_line":"        try:"},{"line_number":5138,"context_line":"            # NOTE(mriedem): If performing a cross-cell migration (resize), we"},{"line_number":5139,"context_line":"            # perform a resize_claim so that (1) the new_flavor usage is"},{"line_number":5140,"context_line":"            # tracked against the compute node and (2) the migration_context"},{"line_number":5141,"context_line":"            # is set on the instance record so networking events can be routed"},{"line_number":5142,"context_line":"            # properly."},{"line_number":5143,"context_line":"            if migration:"}],"source_content_type":"text/x-python","patch_set":9,"id":"3f79a3b5_3fa64ec2","line":5140,"range":{"start_line":5139,"start_character":45,"end_line":5140,"end_character":46},"updated":"2018-10-09 18:47:50.000000000","message":"We can do this with an instance_claim as long as instance.flavor \u003d instance.new_flavor before calling instance_claim. We can control that here before calling the RT.","commit_id":"69d4e44f4b0be361aad0e3fa3b1905ee6686d1ec"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fc7d61fe85fc209b6a6d47516b65ad4947f1cf64","unresolved":false,"context_lines":[{"line_number":5137,"context_line":"        try:"},{"line_number":5138,"context_line":"            # NOTE(mriedem): If performing a cross-cell migration (resize), we"},{"line_number":5139,"context_line":"            # perform a resize_claim so that (1) the new_flavor usage is"},{"line_number":5140,"context_line":"            # tracked against the compute node and (2) the migration_context"},{"line_number":5141,"context_line":"            # is set on the instance record so networking events can be routed"},{"line_number":5142,"context_line":"            # properly."},{"line_number":5143,"context_line":"            if migration:"},{"line_number":5144,"context_line":"                claim_func \u003d rt.resize_claim"},{"line_number":5145,"context_line":"                extra_claim_args \u003d (instance.new_flavor, node, migration,"}],"source_content_type":"text/x-python","patch_set":9,"id":"3f79a3b5_7f85a609","line":5142,"range":{"start_line":5140,"start_character":51,"end_line":5142,"end_character":23},"updated":"2018-10-09 18:47:50.000000000","message":"We can control this by changing the instance mapping to point at the target cell before unshelving. The instance_claim will set the instance.host and the API will route neutron events to that host (we don\u0027t care about the source host getting events because we\u0027ve shelved offloaded from the source host).","commit_id":"69d4e44f4b0be361aad0e3fa3b1905ee6686d1ec"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"ba5a8396e857c8cc0463e82004555e86fcb970e0","unresolved":false,"context_lines":[{"line_number":5196,"context_line":"            if (migration.old_instance_type_id !\u003d"},{"line_number":5197,"context_line":"                    migration.new_instance_type_id):"},{"line_number":5198,"context_line":"                self._set_instance_info(instance, instance.new_flavor)"},{"line_number":5199,"context_line":"            # Copied from ResourceTracker._claim_existing_migration; these"},{"line_number":5200,"context_line":"            # values are saved in _set_migration_status below."},{"line_number":5201,"context_line":"            migration.dest_compute \u003d self.host"},{"line_number":5202,"context_line":"            migration.dest_node \u003d node"},{"line_number":5203,"context_line":"            migration.dest_host \u003d self.driver.get_host_ip_addr()"},{"line_number":5204,"context_line":"        else:"},{"line_number":5205,"context_line":"            vm_state \u003d vm_states.ACTIVE"},{"line_number":5206,"context_line":"        self._update_instance_after_spawn(context, instance, vm_state\u003dvm_state)"}],"source_content_type":"text/x-python","patch_set":9,"id":"3f79a3b5_9f04427f","line":5203,"range":{"start_line":5199,"start_character":12,"end_line":5203,"end_character":64},"updated":"2018-10-09 18:59:22.000000000","message":"We don\u0027t need this if we\u0027re using a resize_claim.","commit_id":"69d4e44f4b0be361aad0e3fa3b1905ee6686d1ec"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"7ac6d9f40b417c3211597fe39944a35f9dea3ddd","unresolved":false,"context_lines":[{"line_number":4958,"context_line":"        # values cannot be nulled out until after updating the resource tracker"},{"line_number":4959,"context_line":"        # though."},{"line_number":4960,"context_line":"        instance.vm_state \u003d vm_states.SHELVED_OFFLOADED"},{"line_number":4961,"context_line":"        # TODO(mriedem): If we\u0027re cross-cell migrating, should we leave the"},{"line_number":4962,"context_line":"        # task_state set?"},{"line_number":4963,"context_line":"        instance.task_state \u003d None"},{"line_number":4964,"context_line":"        instance.save(expected_task_state\u003d[task_states.SHELVING,"},{"line_number":4965,"context_line":"                                           task_states.SHELVING_OFFLOADING])"}],"source_content_type":"text/x-python","patch_set":19,"id":"3f79a3b5_949ff54d","line":4962,"range":{"start_line":4961,"start_character":8,"end_line":4962,"end_character":25},"updated":"2018-12-20 09:49:11.000000000","message":"I guess we should make the state transactions consistant with single-cell migration? seems weird if we got shelved_offloaded state in between","commit_id":"08e5498f92372e2cf34525487a35b3aa98cb93c0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6130fcddc9fe40ab32d469f96da086b51867af17","unresolved":false,"context_lines":[{"line_number":4958,"context_line":"        # values cannot be nulled out until after updating the resource tracker"},{"line_number":4959,"context_line":"        # though."},{"line_number":4960,"context_line":"        instance.vm_state \u003d vm_states.SHELVED_OFFLOADED"},{"line_number":4961,"context_line":"        # TODO(mriedem): If we\u0027re cross-cell migrating, should we leave the"},{"line_number":4962,"context_line":"        # task_state set?"},{"line_number":4963,"context_line":"        instance.task_state \u003d None"},{"line_number":4964,"context_line":"        instance.save(expected_task_state\u003d[task_states.SHELVING,"},{"line_number":4965,"context_line":"                                           task_states.SHELVING_OFFLOADING])"}],"source_content_type":"text/x-python","patch_set":19,"id":"3f79a3b5_d59f9d4c","line":4962,"range":{"start_line":4961,"start_character":8,"end_line":4962,"end_character":25},"in_reply_to":"3f79a3b5_949ff54d","updated":"2018-12-21 15:38:33.000000000","message":"I think in this case we likely want to just not set the vm_state and leave the task_state set to something, because we\u0027re still in the middle of an operation so we don\u0027t want to hit a terminal state at this point.","commit_id":"08e5498f92372e2cf34525487a35b3aa98cb93c0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6130fcddc9fe40ab32d469f96da086b51867af17","unresolved":false,"context_lines":[{"line_number":5135,"context_line":"            vm_state \u003d vm_states.RESIZED"},{"line_number":5136,"context_line":"            if (migration.old_instance_type_id !\u003d"},{"line_number":5137,"context_line":"                    migration.new_instance_type_id):"},{"line_number":5138,"context_line":"                self._set_instance_info(instance, instance.new_flavor)"},{"line_number":5139,"context_line":"            # Copied from ResourceTracker._claim_existing_migration; these"},{"line_number":5140,"context_line":"            # values are saved in _set_migration_status below."},{"line_number":5141,"context_line":"            # TODO(mriedem): We\u0027d need this if we do an instance_claim."}],"source_content_type":"text/x-python","patch_set":19,"id":"3f79a3b5_c2583359","line":5138,"range":{"start_line":5138,"start_character":21,"end_line":5138,"end_character":39},"updated":"2018-12-21 15:38:33.000000000","message":"I just realized why keeping this up to date is important - it\u0027s used for quotas:\n\nhttps://github.com/openstack/nova/blob/905e25a63d3ba25cfbdf492891ac8864fed609ab/nova/objects/instance.py#L1527","commit_id":"08e5498f92372e2cf34525487a35b3aa98cb93c0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4eb79b45836ba999664303391b3b2d54f49e29f1","unresolved":false,"context_lines":[{"line_number":6095,"context_line":""},{"line_number":6096,"context_line":"            # Validate storage for volumes by creating attachments against this"},{"line_number":6097,"context_line":"            # host and connecting them."},{"line_number":6098,"context_line":"            bdms \u003d objects.BlockDeviceMappingList.get_by_instance_uuid("},{"line_number":6099,"context_line":"                ctxt, instance.uuid)"},{"line_number":6100,"context_line":"            connector \u003d self.driver.get_volume_connector(instance)"},{"line_number":6101,"context_line":"            for bdm in bdms:"},{"line_number":6102,"context_line":"                if bdm.is_volume:"}],"source_content_type":"text/x-python","patch_set":20,"id":"1f769fc5_0436bfe7","line":6099,"range":{"start_line":6098,"start_character":12,"end_line":6099,"end_character":36},"updated":"2019-01-02 16:27:05.000000000","message":"This won\u0027t work because the instance doesn\u0027t exist in the target cell db yet. This works in functional tests because of the CheatingSerializer fixture and because the CellDatabase fixture defaults to cell1 if not targeted specifically to another cell.","commit_id":"bc79de13d4e314a00c6c9789d6ce503c9ef13fd7"}],"nova/compute/resource_tracker.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bc78e278073ea9df1c652d5f252ca8883c7abbe7","unresolved":false,"context_lines":[{"line_number":1308,"context_line":"            if instance.deleted:"},{"line_number":1309,"context_line":"                # The instance is gone, so we definitely want to remove"},{"line_number":1310,"context_line":"                # allocations associated with it."},{"line_number":1311,"context_line":"                # NOTE(jaypipes): This will not be true if/when we support"},{"line_number":1312,"context_line":"                # cross-cell migrations..."},{"line_number":1313,"context_line":"                LOG.debug(\"Instance %s has been deleted (perhaps locally). \""},{"line_number":1314,"context_line":"                          \"Deleting allocations that remained for this \""},{"line_number":1315,"context_line":"                          \"instance against this compute host: %s.\","}],"source_content_type":"text/x-python","patch_set":14,"id":"3f79a3b5_28011a08","line":1312,"range":{"start_line":1311,"start_character":16,"end_line":1312,"end_character":42},"updated":"2018-11-05 20:24:02.000000000","message":"Need to think about this...but we only delete the instance from the target cell db on revert and from the source cell db on confirm, so I\u0027m not sure why it would matter here.","commit_id":"9213fdb10af0ff9d5266370ebba63b35303821d7"}],"nova/compute/utils.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1c05920f5033cf391c0b546f0345abb80c5d084e","unresolved":false,"context_lines":[{"line_number":1057,"context_line":"            del (instance.system_metadata[key])"},{"line_number":1058,"context_line":""},{"line_number":1059,"context_line":""},{"line_number":1060,"context_line":"def shelve(context, instance, compute_rpcapi, image_api, clean_shutdown\u003dTrue,"},{"line_number":1061,"context_line":"           offload\u003dFalse, migration\u003dNone):"},{"line_number":1062,"context_line":"    \"\"\"Shelve the given instance."},{"line_number":1063,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"3f79a3b5_aa1c297b","line":1060,"updated":"2018-11-06 17:30:05.000000000","message":"Should split this out into it\u0027s own change since it\u0027s just a refactor.\n\nI think I needed this to control the immediate offload action because otherwise shelve will only offload based on the shelved_offload_time configuration. The other thing was the revert flow in conductor needed the instance actions created by the API (I think?) otherwise it blows up on compute b/c it fails to find the action to record events. Might have also needed the snapshot to get created in the API so we can upload the data to it.","commit_id":"9213fdb10af0ff9d5266370ebba63b35303821d7"}],"nova/conductor/manager.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"79d971ab4bad12aa1ce1bfe6e73b71fc17f00c51","unresolved":false,"context_lines":[{"line_number":276,"context_line":"            # Code downstream may expect extra_specs to be populated since it"},{"line_number":277,"context_line":"            # is receiving an object, so lookup the flavor to ensure this."},{"line_number":278,"context_line":"            flavor \u003d objects.Flavor.get_by_id(context, flavor[\u0027id\u0027])"},{"line_number":279,"context_line":"        # TODO(mriedem): The rebuild parameter is always False and should"},{"line_number":280,"context_line":"        # eventually be removed."},{"line_number":281,"context_line":"        if live and not rebuild and not flavor:"},{"line_number":282,"context_line":"            self._live_migrate(context, instance, scheduler_hint,"}],"source_content_type":"text/x-python","patch_set":1,"id":"3f79a3b5_78c54e5b","line":279,"updated":"2018-09-19 23:44:35.000000000","message":"Pull this out into a separate change outside the series.","commit_id":"dfdcc918fcfff4023479a26934d8619a575abb6d"}],"nova/conductor/tasks/cross_cell_migrate.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e0f42732315a4ff5baed545ad769c0bc52fdd890","unresolved":false,"context_lines":[{"line_number":263,"context_line":""},{"line_number":264,"context_line":"        # RPC cast to the target compute service to unshelve the instance in"},{"line_number":265,"context_line":"        # the target cell."},{"line_number":266,"context_line":"        self.compute_rpcapi.unshelve_instance("},{"line_number":267,"context_line":"            cctxt, instance, self.host_selection.service_host,"},{"line_number":268,"context_line":"            image\u003dimage, filter_properties\u003dfilter_properties,"},{"line_number":269,"context_line":"            node\u003dself.host_selection.nodename)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f79a3b5_ccdcbe72","line":266,"updated":"2018-09-21 15:01:47.000000000","message":"We need to plumb the new flavor down to unshelve so we can resize when we create the guest.","commit_id":"38d6d0a7a0b036186f73d61fa4611a8777268c0c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6a1829ef36e5046b71c0fe88498afa507a3db2ca","unresolved":false,"context_lines":[{"line_number":263,"context_line":""},{"line_number":264,"context_line":"        # RPC cast to the target compute service to unshelve the instance in"},{"line_number":265,"context_line":"        # the target cell."},{"line_number":266,"context_line":"        self.compute_rpcapi.unshelve_instance("},{"line_number":267,"context_line":"            cctxt, instance, self.host_selection.service_host,"},{"line_number":268,"context_line":"            image\u003dimage, filter_properties\u003dfilter_properties,"},{"line_number":269,"context_line":"            node\u003dself.host_selection.nodename)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f79a3b5_b20f338a","line":266,"in_reply_to":"3f79a3b5_ccdcbe72","updated":"2018-09-24 20:39:34.000000000","message":"Done","commit_id":"38d6d0a7a0b036186f73d61fa4611a8777268c0c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e0f42732315a4ff5baed545ad769c0bc52fdd890","unresolved":false,"context_lines":[{"line_number":288,"context_line":"                LOG.exception(\u0027Timed out waiting for instance to unshelve \u0027"},{"line_number":289,"context_line":"                              \u0027from the target host.\u0027, instance\u003dself.instance)"},{"line_number":290,"context_line":""},{"line_number":291,"context_line":"    def _execute(self):"},{"line_number":292,"context_line":"        # Should these things be broken down into tasks themselves? Should"},{"line_number":293,"context_line":"        # this use taskflow to help with the task orchestration so it doesn\u0027t"},{"line_number":294,"context_line":"        # become a monster like LiveMigrationTask?"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f79a3b5_ec965a94","line":291,"updated":"2018-09-21 15:01:47.000000000","message":"TODO: instance actions might be weird as a result of how this is orchestrated - a functional test should trap and count the instance actions to see if it makes sense.","commit_id":"38d6d0a7a0b036186f73d61fa4611a8777268c0c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e0f42732315a4ff5baed545ad769c0bc52fdd890","unresolved":false,"context_lines":[{"line_number":305,"context_line":"        self.instance.availability_zone \u003d ("},{"line_number":306,"context_line":"            availability_zones.get_host_availability_zone("},{"line_number":307,"context_line":"                self.context, self.host_selection.service_host))"},{"line_number":308,"context_line":"        # Before we unshelve, set the task_state so a user can\u0027t do something"},{"line_number":309,"context_line":"        # with the instance while we\u0027re still migrating; this will also refresh"},{"line_number":310,"context_line":"        # the instance so we have the latest information like the"},{"line_number":311,"context_line":"        # shelved_image_id (if not volume-backed) in the instance system"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f79a3b5_0cd71651","line":308,"updated":"2018-09-21 15:01:47.000000000","message":"This is also needed so when ComputeManager._unshelve_instance changes the instance status it doesn\u0027t blow up.","commit_id":"38d6d0a7a0b036186f73d61fa4611a8777268c0c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6a1829ef36e5046b71c0fe88498afa507a3db2ca","unresolved":false,"context_lines":[{"line_number":305,"context_line":"        self.instance.availability_zone \u003d ("},{"line_number":306,"context_line":"            availability_zones.get_host_availability_zone("},{"line_number":307,"context_line":"                self.context, self.host_selection.service_host))"},{"line_number":308,"context_line":"        # Before we unshelve, set the task_state so a user can\u0027t do something"},{"line_number":309,"context_line":"        # with the instance while we\u0027re still migrating; this will also refresh"},{"line_number":310,"context_line":"        # the instance so we have the latest information like the"},{"line_number":311,"context_line":"        # shelved_image_id (if not volume-backed) in the instance system"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f79a3b5_32232309","line":308,"in_reply_to":"3f79a3b5_0cd71651","updated":"2018-09-24 20:39:34.000000000","message":"Done","commit_id":"38d6d0a7a0b036186f73d61fa4611a8777268c0c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e0f42732315a4ff5baed545ad769c0bc52fdd890","unresolved":false,"context_lines":[{"line_number":320,"context_line":"            # back into the source cell by calling"},{"line_number":321,"context_line":"            # ComputeTaskManager.unshelve_instance?"},{"line_number":322,"context_line":"            instance \u003d self._create_instance_in_target_cell(cctxt)"},{"line_number":323,"context_line":"            self._unshelve_in_target_cell(cctxt, instance)"},{"line_number":324,"context_line":""},{"line_number":325,"context_line":"        # Now we can update the instance mapping to point at the target cell"},{"line_number":326,"context_line":"        # since we successfully unshelved there."}],"source_content_type":"text/x-python","patch_set":2,"id":"3f79a3b5_8c9d66bc","line":323,"updated":"2018-09-21 15:01:47.000000000","message":"Need to change the vm_state to VERIFY_RESIZE...","commit_id":"38d6d0a7a0b036186f73d61fa4611a8777268c0c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6a1829ef36e5046b71c0fe88498afa507a3db2ca","unresolved":false,"context_lines":[{"line_number":320,"context_line":"            # back into the source cell by calling"},{"line_number":321,"context_line":"            # ComputeTaskManager.unshelve_instance?"},{"line_number":322,"context_line":"            instance \u003d self._create_instance_in_target_cell(cctxt)"},{"line_number":323,"context_line":"            self._unshelve_in_target_cell(cctxt, instance)"},{"line_number":324,"context_line":""},{"line_number":325,"context_line":"        # Now we can update the instance mapping to point at the target cell"},{"line_number":326,"context_line":"        # since we successfully unshelved there."}],"source_content_type":"text/x-python","patch_set":2,"id":"3f79a3b5_d2798ffb","line":323,"in_reply_to":"3f79a3b5_8c9d66bc","updated":"2018-09-24 20:39:34.000000000","message":"Actually unshelve_instance in the compute service should do this.","commit_id":"38d6d0a7a0b036186f73d61fa4611a8777268c0c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2fc4ded8287ef44a33b37c81ed3973601758ae09","unresolved":false,"context_lines":[{"line_number":229,"context_line":"        \"\"\""},{"line_number":230,"context_line":"        LOG.info(\u0027Creating instance and its related records in the target \u0027"},{"line_number":231,"context_line":"                 \u0027cell: %s\u0027, cctxt.cell_uuid, instance\u003dself.instance)"},{"line_number":232,"context_line":"        # We also have to create the BDMs and tags separately, just like in"},{"line_number":233,"context_line":"        # ComputeTaskManager.schedule_and_build_instances, so get those out"},{"line_number":234,"context_line":"        # of the database first before we start creating anything."},{"line_number":235,"context_line":"        bdms \u003d objects.BlockDeviceMappingList.get_by_instance_uuid("}],"source_content_type":"text/x-python","patch_set":9,"id":"3f79a3b5_3eaf10e1","line":232,"updated":"2018-10-10 20:20:44.000000000","message":"What about ConsoleAuthToken and VirtualInterface (for port device tags?) resources? A new token could be regenerated, but we could lose the device tag if we don\u0027t copy the vif over - add a wrinkle to the functional tests for that case.","commit_id":"69d4e44f4b0be361aad0e3fa3b1905ee6686d1ec"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"988f9f8f7aaee6562b1893cbda32007ba9d5e006","unresolved":false,"context_lines":[{"line_number":771,"context_line":"        # TODO(mriedem): Do we want to create separate tasks for this? Probably"},{"line_number":772,"context_line":"        # would make organizing it easier."},{"line_number":773,"context_line":""},{"line_number":774,"context_line":"        # We need to destroy the guest on the target hypervisor, and probably"},{"line_number":775,"context_line":"        # snapshot any changes to the guest before unshelving it back on the"},{"line_number":776,"context_line":"        # source host in the source cell, so we need to shelve offload the"},{"line_number":777,"context_line":"        # instance from the target cell. We need to do this before unshelving"},{"line_number":778,"context_line":"        # on the source otherwise the shelve offload will delete the resource"},{"line_number":779,"context_line":"        # allocations created by the scheduler."},{"line_number":780,"context_line":"        self._shelve_offload_from_target_cell()"},{"line_number":781,"context_line":"        self.instance.refresh()"},{"line_number":782,"context_line":"        LOG.info(\u0027Shelved offloaded instance from target cell \u0027"},{"line_number":783,"context_line":"                 \u0027shelved_image_id: %s\u0027,"}],"source_content_type":"text/x-python","patch_set":9,"id":"3f79a3b5_199a76c3","line":780,"range":{"start_line":774,"start_character":8,"end_line":780,"end_character":47},"updated":"2018-10-10 16:27:17.000000000","message":"Check normal resize case for revert - do we throw away any changes that happened on the dest? If so, we don\u0027t need to shelve offload from target on revert which generates a new snapshot. Plus if you resized to a larger disk, the snapshot on revert might be too big to unshelve. So maybe just destroy here and wait for it to be gone in the dest.\n\nOne issue with calling terminate_instance on the target is it might try to delete volumes and ports...maybe we should shelve offload from target but tell it to not snapshot. What if we need to rollback though in case the unshelve fails in the source? Do we unshelve in the target with the original snapshot image ref? You can\u0027t rebuild the instance in that case because it wouldn\u0027t be on a host.","commit_id":"69d4e44f4b0be361aad0e3fa3b1905ee6686d1ec"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"5d6fcd896d5015b36b9077fc392b8c6da407ae52","unresolved":false,"context_lines":[{"line_number":558,"context_line":"        try:"},{"line_number":559,"context_line":"            # TODO(mriedem): This doesn\u0027t return alternates by default, do"},{"line_number":560,"context_line":"            # we want alternates to do some kind of reschedule logic?"},{"line_number":561,"context_line":"            host_lists \u003d self._schedule_instances("},{"line_number":562,"context_line":"                self.context, self.request_spec, [self.instance.uuid])"},{"line_number":563,"context_line":"        except (exception.NoValidHost,"},{"line_number":564,"context_line":"                exception.UnsupportedPolicyException):"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_4ce9ea16","line":561,"range":{"start_line":561,"start_character":30,"end_line":561,"end_character":49},"updated":"2018-11-07 00:34:21.000000000","message":"If the migration record holds resource allocations against the source compute and it\u0027s full, this will fail because the scheduler will try to claim resources against it again. We should delete the migration-based allocations prior to this step.","commit_id":"f5a04460e490835611aab979d11bad2298f668f8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"9f1bf9142df003e7905bced6a593fd69b47212b7","unresolved":false,"context_lines":[{"line_number":558,"context_line":"        try:"},{"line_number":559,"context_line":"            # TODO(mriedem): This doesn\u0027t return alternates by default, do"},{"line_number":560,"context_line":"            # we want alternates to do some kind of reschedule logic?"},{"line_number":561,"context_line":"            host_lists \u003d self._schedule_instances("},{"line_number":562,"context_line":"                self.context, self.request_spec, [self.instance.uuid])"},{"line_number":563,"context_line":"        except (exception.NoValidHost,"},{"line_number":564,"context_line":"                exception.UnsupportedPolicyException):"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_85046cc5","line":561,"range":{"start_line":561,"start_character":30,"end_line":561,"end_character":49},"in_reply_to":"3f79a3b5_4ce9ea16","updated":"2018-12-10 22:42:25.000000000","message":"Adding a note for this, but even if we unshelve directly on the source, we need to pass the limits dict for pci/numa claims which only come from the scheduler and the RequestSpec.limits probably can\u0027t be trusted, for one thing we don\u0027t revert them on resize revert in the API like we do for the flavor:\n\nhttps://github.com/openstack/nova/blob/08d617084e5aa69ada0898d674022621d130aef3/nova/compute/api.py#L3489\n\nIf we really needed to, we could maybe stash the old limits in a migration_context but that\u0027s really hacky and error-prone.","commit_id":"f5a04460e490835611aab979d11bad2298f668f8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"5d6fcd896d5015b36b9077fc392b8c6da407ae52","unresolved":false,"context_lines":[{"line_number":863,"context_line":"        # in glance...). Maybe we need to preserve the shelved_image_id system"},{"line_number":864,"context_line":"        # metadata until we confirm/revert and never create a second shelve"},{"line_number":865,"context_line":"        # snapshot on revert?"},{"line_number":866,"context_line":"        self._shelve_offload_from_target_cell()"},{"line_number":867,"context_line":"        LOG.info(\u0027Shelved offloaded instance from target cell\u0027,"},{"line_number":868,"context_line":"                 instance\u003dself.instance)"},{"line_number":869,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_acc0be7e","line":866,"updated":"2018-11-07 00:34:21.000000000","message":"We should maybe select a host in the source cell before shelve offloading the guest from the target cell in case something goes wrong during scheduling.\n\nHell, maybe we should only shelve offload from the target cell *after* the instance is successfully unshelved in the source cell?","commit_id":"f5a04460e490835611aab979d11bad2298f668f8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"9f1bf9142df003e7905bced6a593fd69b47212b7","unresolved":false,"context_lines":[{"line_number":863,"context_line":"        # in glance...). Maybe we need to preserve the shelved_image_id system"},{"line_number":864,"context_line":"        # metadata until we confirm/revert and never create a second shelve"},{"line_number":865,"context_line":"        # snapshot on revert?"},{"line_number":866,"context_line":"        self._shelve_offload_from_target_cell()"},{"line_number":867,"context_line":"        LOG.info(\u0027Shelved offloaded instance from target cell\u0027,"},{"line_number":868,"context_line":"                 instance\u003dself.instance)"},{"line_number":869,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_258318a9","line":866,"in_reply_to":"3f79a3b5_acc0be7e","updated":"2018-12-10 22:42:25.000000000","message":"Adding a TODO so I don\u0027t lose this thought.","commit_id":"f5a04460e490835611aab979d11bad2298f668f8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"5d6fcd896d5015b36b9077fc392b8c6da407ae52","unresolved":false,"context_lines":[{"line_number":878,"context_line":"        with nova_context.target_cell("},{"line_number":879,"context_line":"                self.context, source_host_mapping.cell_mapping) as cctxt:"},{"line_number":880,"context_line":"            inst \u003d self._update_instance_in_source_cell(cctxt, selection)"},{"line_number":881,"context_line":"            self._unshelve_in_source_cell(cctxt, inst, selection)"},{"line_number":882,"context_line":""},{"line_number":883,"context_line":"            # Update the migration record from the source cell database because"},{"line_number":884,"context_line":"            # we\u0027re going to delete the migration record from the target cell"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_cc8c1a3b","line":881,"range":{"start_line":881,"start_character":12,"end_line":881,"end_character":65},"updated":"2018-11-07 00:34:21.000000000","message":"We have to update the instance mapping before this otherwise the network-vif-plugged event will go to the wrong cell/host.","commit_id":"f5a04460e490835611aab979d11bad2298f668f8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"9f1bf9142df003e7905bced6a593fd69b47212b7","unresolved":false,"context_lines":[{"line_number":878,"context_line":"        with nova_context.target_cell("},{"line_number":879,"context_line":"                self.context, source_host_mapping.cell_mapping) as cctxt:"},{"line_number":880,"context_line":"            inst \u003d self._update_instance_in_source_cell(cctxt, selection)"},{"line_number":881,"context_line":"            self._unshelve_in_source_cell(cctxt, inst, selection)"},{"line_number":882,"context_line":""},{"line_number":883,"context_line":"            # Update the migration record from the source cell database because"},{"line_number":884,"context_line":"            # we\u0027re going to delete the migration record from the target cell"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_8530ec06","line":881,"range":{"start_line":881,"start_character":12,"end_line":881,"end_character":65},"in_reply_to":"3f79a3b5_cc8c1a3b","updated":"2018-12-10 22:42:25.000000000","message":"Added a FIXME comment to the code.","commit_id":"f5a04460e490835611aab979d11bad2298f668f8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"5d6fcd896d5015b36b9077fc392b8c6da407ae52","unresolved":false,"context_lines":[{"line_number":903,"context_line":"        # database."},{"line_number":904,"context_line":"        self.instance.destroy()"},{"line_number":905,"context_line":""},{"line_number":906,"context_line":"        self._cleanup_allocations()"},{"line_number":907,"context_line":""},{"line_number":908,"context_line":"    def rollback(self):"},{"line_number":909,"context_line":"        # TODO(mriedem): Rollback everything; would be easier to break"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f79a3b5_ec7a3625","line":906,"range":{"start_line":906,"start_character":13,"end_line":906,"end_character":33},"updated":"2018-11-07 00:34:21.000000000","message":"This seems wrong. We need to drop the migration-based allocations against the source host *before* scheduling so we don\u0027t risk NoValidHost if the source host is at capacity. And when shelve offloading from the target host, wouldn\u0027t it delete the allocations held by the instance against the target host?","commit_id":"f5a04460e490835611aab979d11bad2298f668f8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"57ca4d7d2076dbfd4db6544774160247a066f637","unresolved":false,"context_lines":[{"line_number":371,"context_line":"        # become a monster like LiveMigrationTask?"},{"line_number":372,"context_line":""},{"line_number":373,"context_line":"        self._verify_target_host(self.host_selection.service_host)"},{"line_number":374,"context_line":"        # TODO(mriedem): reschedule if the host fails validation; do we"},{"line_number":375,"context_line":"        # restrict to only get hosts from the target cell at this point since"},{"line_number":376,"context_line":"        # we\u0027re committed to the cross-cell resize flow using shelve?"},{"line_number":377,"context_line":""},{"line_number":378,"context_line":"        # Perist that this migration is a cross-cell resize. This will be"},{"line_number":379,"context_line":"        # needed in the API to confirm/revert properly."}],"source_content_type":"text/x-python","patch_set":18,"id":"3f79a3b5_eef91950","line":376,"range":{"start_line":374,"start_character":64,"end_line":376,"end_character":69},"updated":"2018-12-14 21:56:45.000000000","message":"This isn\u0027t a problem, the alternates will already be in the same cell as the primary selected host:\n\nhttps://github.com/openstack/nova/blob/bb446c66ec1b9858e343bbfcddb6e3bdc916b431/nova/scheduler/filter_scheduler.py#L409","commit_id":"903b944ef39c7ad353ef6ca39d69c697ba113075"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"d0b295b6f9e0037a4a3bf3a943ccc879028c61a7","unresolved":false,"context_lines":[{"line_number":371,"context_line":"        # become a monster like LiveMigrationTask?"},{"line_number":372,"context_line":""},{"line_number":373,"context_line":"        self._verify_target_host(self.host_selection.service_host)"},{"line_number":374,"context_line":"        # TODO(mriedem): reschedule if the host fails validation; do we"},{"line_number":375,"context_line":"        # restrict to only get hosts from the target cell at this point since"},{"line_number":376,"context_line":"        # we\u0027re committed to the cross-cell resize flow using shelve?"},{"line_number":377,"context_line":""},{"line_number":378,"context_line":"        # Perist that this migration is a cross-cell resize. This will be"},{"line_number":379,"context_line":"        # needed in the API to confirm/revert properly."}],"source_content_type":"text/x-python","patch_set":18,"id":"3f79a3b5_21229ea6","line":376,"range":{"start_line":374,"start_character":64,"end_line":376,"end_character":69},"in_reply_to":"3f79a3b5_eef91950","updated":"2018-12-18 02:39:47.000000000","message":"Done","commit_id":"903b944ef39c7ad353ef6ca39d69c697ba113075"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"c6b3f3980e64c4b9c050b9ce711c238ddde448d4","unresolved":false,"context_lines":[{"line_number":140,"context_line":"        # to connect the volume on the target host (to determine we can reach"},{"line_number":141,"context_line":"        # storage on that host across cells)."},{"line_number":142,"context_line":"        try:"},{"line_number":143,"context_line":"            self.compute_rpcapi.check_can_cross_cell_resize("},{"line_number":144,"context_line":"                self.context, self.instance, destination)"},{"line_number":145,"context_line":"        except messaging.MessagingTimeout:"},{"line_number":146,"context_line":"            msg \u003d _(\u0027RPC timeout while checking if we can cross-cell migrate \u0027"}],"source_content_type":"text/x-python","patch_set":20,"id":"1f769fc5_f5a49d0a","line":143,"updated":"2018-12-31 17:07:00.000000000","message":"If we\u0027re going to create a migration_context and do claims anyway, it might not be a bad idea to have this do the RT.resize_claim in addition to validating port bindings and volume attachments, because the RT.resize_claim will create the MigrationContext for us, which would also be similar to how prep_resize works for a normal resize.","commit_id":"bc79de13d4e314a00c6c9789d6ce503c9ef13fd7"}],"nova/conductor/tasks/migrate.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"79d971ab4bad12aa1ce1bfe6e73b71fc17f00c51","unresolved":false,"context_lines":[{"line_number":166,"context_line":""},{"line_number":167,"context_line":"        return migration"},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"    def _restrict_request_spec_to_cell(self, legacy_props):"},{"line_number":170,"context_line":"        # NOTE(mriedem): If the user is allowed to perform a cross-cell resize"},{"line_number":171,"context_line":"        # then add the current cell to the request spec as \"preferred\" so the"},{"line_number":172,"context_line":"        # scheduler will weigh hosts within the current cell over hosts in"}],"source_content_type":"text/x-python","patch_set":1,"id":"3f79a3b5_58bf32cf","line":169,"updated":"2018-09-19 23:44:35.000000000","message":"Split this out into a separate refactor change.","commit_id":"dfdcc918fcfff4023479a26934d8619a575abb6d"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"79d971ab4bad12aa1ce1bfe6e73b71fc17f00c51","unresolved":false,"context_lines":[{"line_number":223,"context_line":"        return True"},{"line_number":224,"context_line":""},{"line_number":225,"context_line":"    def _execute(self):"},{"line_number":226,"context_line":"        # TODO(sbauza): Remove that once prep_resize() accepts a  RequestSpec"},{"line_number":227,"context_line":"        # object in the signature and all the scheduler.utils methods too"},{"line_number":228,"context_line":"        legacy_spec \u003d self.request_spec.to_legacy_request_spec_dict()"},{"line_number":229,"context_line":"        legacy_props \u003d self.request_spec.to_legacy_filter_properties_dict()"}],"source_content_type":"text/x-python","patch_set":1,"id":"3f79a3b5_f8a63ec0","line":226,"updated":"2018-09-19 23:44:35.000000000","message":"Could fix https://review.openstack.org/#/c/582417/ and then rebase on top of that to remove this (very old) TODO.","commit_id":"dfdcc918fcfff4023479a26934d8619a575abb6d"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"7ac6d9f40b417c3211597fe39944a35f9dea3ddd","unresolved":false,"context_lines":[{"line_number":202,"context_line":"        self.request_spec.requested_destination.allow_cross_cell_move \u003d ("},{"line_number":203,"context_line":"            allow_cross_cell_resize)"},{"line_number":204,"context_line":"        if allow_cross_cell_resize:"},{"line_number":205,"context_line":"            LOG.debug(\u0027Preferring cell %(cell)s while migrating\u0027,"},{"line_number":206,"context_line":"                      {\u0027cell\u0027: instance_mapping.cell_mapping.identity},"},{"line_number":207,"context_line":"                      instance\u003dself.instance)"},{"line_number":208,"context_line":"        else:"},{"line_number":209,"context_line":"            LOG.debug(\u0027Restricting to cell %(cell)s while migrating\u0027,"},{"line_number":210,"context_line":"                      {\u0027cell\u0027: instance_mapping.cell_mapping.identity},"}],"source_content_type":"text/x-python","patch_set":17,"id":"3f79a3b5_b9e0ecf7","line":207,"range":{"start_line":205,"start_character":12,"end_line":207,"end_character":45},"updated":"2018-12-20 09:49:11.000000000","message":"this might depend on the weigher multiplexer","commit_id":"24f1c3c7543ea457df2d5ca7bd25bd92d59bc1af"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6130fcddc9fe40ab32d469f96da086b51867af17","unresolved":false,"context_lines":[{"line_number":202,"context_line":"        self.request_spec.requested_destination.allow_cross_cell_move \u003d ("},{"line_number":203,"context_line":"            allow_cross_cell_resize)"},{"line_number":204,"context_line":"        if allow_cross_cell_resize:"},{"line_number":205,"context_line":"            LOG.debug(\u0027Preferring cell %(cell)s while migrating\u0027,"},{"line_number":206,"context_line":"                      {\u0027cell\u0027: instance_mapping.cell_mapping.identity},"},{"line_number":207,"context_line":"                      instance\u003dself.instance)"},{"line_number":208,"context_line":"        else:"},{"line_number":209,"context_line":"            LOG.debug(\u0027Restricting to cell %(cell)s while migrating\u0027,"},{"line_number":210,"context_line":"                      {\u0027cell\u0027: instance_mapping.cell_mapping.identity},"}],"source_content_type":"text/x-python","patch_set":17,"id":"3f79a3b5_c206f322","line":207,"range":{"start_line":205,"start_character":12,"end_line":207,"end_character":45},"in_reply_to":"3f79a3b5_b9e0ecf7","updated":"2018-12-21 15:38:33.000000000","message":"Yeah I should probably re-word this, and here as well:\n\nhttps://review.openstack.org/#/c/614353/4/nova/scheduler/weights/cross_cell.py@52","commit_id":"24f1c3c7543ea457df2d5ca7bd25bd92d59bc1af"}],"nova/objects/request_spec.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1c3d9c5aa0ea931a3e86724c87e5eb35d3a19776","unresolved":false,"context_lines":[{"line_number":753,"context_line":"        \u0027cross_cell_move\u0027: fields.BooleanField(default\u003dFalse)"},{"line_number":754,"context_line":"    }"},{"line_number":755,"context_line":""},{"line_number":756,"context_line":"    def obj_make_compatible(self, primitive, target_version):"},{"line_number":757,"context_line":"        super(Destination, self).obj_make_compatible(primitive, target_version)"},{"line_number":758,"context_line":"        target_version \u003d versionutils.convert_version_to_tuple(target_version)"},{"line_number":759,"context_line":"        if target_version \u003c (1, 2):"}],"source_content_type":"text/x-python","patch_set":11,"id":"3f79a3b5_56559ebf","line":756,"range":{"start_line":756,"start_character":8,"end_line":756,"end_character":27},"updated":"2018-10-29 20:08:52.000000000","message":"Need to handle this in obj_make_compatible.","commit_id":"72db00a90c9d759a23aeb564a2bdd88b89d1b00a"}],"nova/tests/functional/test_cross_cell_migrate.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"5a68f0e9f30dc23575f8e4f9eaff97dad5578242","unresolved":false,"context_lines":[{"line_number":138,"context_line":"        server \u003d self._wait_for_state_change(self.api, server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":139,"context_line":"        expected_host \u003d \u0027host1\u0027 if original_host \u003d\u003d \u0027host2\u0027 else \u0027host2\u0027"},{"line_number":140,"context_line":"        self.assertEqual(expected_host, server[\u0027OS-EXT-SRV-ATTR:host\u0027])"},{"line_number":141,"context_line":"        # Assert that the instance is only listed one time from the API (to"},{"line_number":142,"context_line":"        # make sure it\u0027s not listed out of both cells)."},{"line_number":143,"context_line":"        servers \u003d self.api.get_servers(detail\u003dFalse)"},{"line_number":144,"context_line":"        self.assertEqual(1, len(servers),"},{"line_number":145,"context_line":"                         \u0027Unexpected number of servers: %s\u0027 % servers)"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"        # And that there is only one migration record."},{"line_number":148,"context_line":"        migrations \u003d self.api.api_get("}],"source_content_type":"text/x-python","patch_set":17,"id":"3f79a3b5_0e1a55c7","line":145,"range":{"start_line":141,"start_character":8,"end_line":145,"end_character":70},"updated":"2018-12-03 21:50:58.000000000","message":"I think we\u0027re getting lucky here because the servers view builder is keying off instance UUID so we\u0027re only getting the last instance record processed out of the cells, which might be the wrong one - how do we assert it\u0027s the one we want? Maybe need to check the expected_host?","commit_id":"24f1c3c7543ea457df2d5ca7bd25bd92d59bc1af"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"828b28326d3a58d36ff74fe7d0c6efcef65794b5","unresolved":false,"context_lines":[{"line_number":138,"context_line":"        server \u003d self._wait_for_state_change(self.api, server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":139,"context_line":"        expected_host \u003d \u0027host1\u0027 if original_host \u003d\u003d \u0027host2\u0027 else \u0027host2\u0027"},{"line_number":140,"context_line":"        self.assertEqual(expected_host, server[\u0027OS-EXT-SRV-ATTR:host\u0027])"},{"line_number":141,"context_line":"        # Assert that the instance is only listed one time from the API (to"},{"line_number":142,"context_line":"        # make sure it\u0027s not listed out of both cells)."},{"line_number":143,"context_line":"        servers \u003d self.api.get_servers(detail\u003dFalse)"},{"line_number":144,"context_line":"        self.assertEqual(1, len(servers),"},{"line_number":145,"context_line":"                         \u0027Unexpected number of servers: %s\u0027 % servers)"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"        # And that there is only one migration record."},{"line_number":148,"context_line":"        migrations \u003d self.api.api_get("}],"source_content_type":"text/x-python","patch_set":17,"id":"3f79a3b5_b75c3bef","line":145,"range":{"start_line":141,"start_character":8,"end_line":145,"end_character":70},"in_reply_to":"3f79a3b5_0e1a55c7","updated":"2018-12-10 22:44:52.000000000","message":"Done","commit_id":"24f1c3c7543ea457df2d5ca7bd25bd92d59bc1af"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"00e608ac2c5d9f62568c0df224fef6f703b82269","unresolved":false,"context_lines":[{"line_number":440,"context_line":""},{"line_number":441,"context_line":"        # TODO(mriedem): Assert the ComputeManager._set_instance_info fields"},{"line_number":442,"context_line":"        # are correct after the revert."},{"line_number":443,"context_line":""},{"line_number":444,"context_line":"    # TODO(mriedem): Test cross-cell list where the source cell has two"},{"line_number":445,"context_line":"    # hosts so the CrossCellWeigher picks the other host in the source cell"},{"line_number":446,"context_line":"    # and we do a traditional resize. Add a variant on this where the flavor"}],"source_content_type":"text/x-python","patch_set":19,"id":"1f769fc5_1d74fc34","line":443,"updated":"2018-12-26 16:38:56.000000000","message":"Need a test where we delete the server while in VERIFY_RESIZE status and assert that when listing the server it doesn\u0027t show up in the results (because as written right now, the server would still be in the source cell DB). IOW, the delete flow is not taking into account the server being in both DBs.","commit_id":"08e5498f92372e2cf34525487a35b3aa98cb93c0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"560df3668429175a70d09154a2a50dfe2b547b25","unresolved":false,"context_lines":[{"line_number":440,"context_line":""},{"line_number":441,"context_line":"        # TODO(mriedem): Assert the ComputeManager._set_instance_info fields"},{"line_number":442,"context_line":"        # are correct after the revert."},{"line_number":443,"context_line":""},{"line_number":444,"context_line":"    # TODO(mriedem): Test cross-cell list where the source cell has two"},{"line_number":445,"context_line":"    # hosts so the CrossCellWeigher picks the other host in the source cell"},{"line_number":446,"context_line":"    # and we do a traditional resize. Add a variant on this where the flavor"}],"source_content_type":"text/x-python","patch_set":19,"id":"1f769fc5_b2e63b16","line":443,"in_reply_to":"1f769fc5_1d74fc34","updated":"2018-12-31 15:12:04.000000000","message":"Done","commit_id":"08e5498f92372e2cf34525487a35b3aa98cb93c0"}]}
