)]}'
{"doc/source/admin/virtual-gpu.rst":[{"author":{"_account_id":26458,"name":"Brin Zhang","email":"zhangbailin@inspur.com","username":"zhangbailin"},"change_message_id":"bc9a1842d3ee529157de08f5c13b274e0a24044d","unresolved":false,"context_lines":[{"line_number":407,"context_line":""},{"line_number":408,"context_line":"* Multiple GPU types per compute is not supported by the XenServer driver."},{"line_number":409,"context_line":""},{"line_number":410,"context_line":".. _bug 1778563: https://launchpad.net/bugs/1778563"},{"line_number":411,"context_line":".. _bug 1762688: https://bugs.launchpad.net/nova/+bug/1762688"},{"line_number":412,"context_line":""},{"line_number":413,"context_line":".. Links"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f4c43b2_ddbd1cd9","line":410,"range":{"start_line":410,"start_character":17,"end_line":410,"end_character":51},"updated":"2020-04-20 10:08:43.000000000","message":"nit: maybe it should be changed to https://bugs.launchpad.net/nova/+bug/1778563","commit_id":"b5dcbd8a7e022e75a75fe6ed8262a20b92a86cc3"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"df2ee35525a3ddf81b2bb90745dd2a6163f5eafe","unresolved":false,"context_lines":[{"line_number":345,"context_line":""},{"line_number":346,"context_line":".. note::"},{"line_number":347,"context_line":""},{"line_number":348,"context_line":"   This information is correct as of the 17.0.0 Queens release. Where"},{"line_number":349,"context_line":"   improvements have been made or issues fixed, they are noted per item."},{"line_number":350,"context_line":""},{"line_number":351,"context_line":"For libvirt:"}],"source_content_type":"text/x-rst","patch_set":7,"id":"1f493fa4_c1db067b","line":348,"range":{"start_line":348,"start_character":41,"end_line":348,"end_character":54},"updated":"2020-04-20 17:21:29.000000000","message":"21.0.0 (Ussuri)","commit_id":"d2e0afc1f72db5cb56ed987e2873798fc1e89545"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"df2ee35525a3ddf81b2bb90745dd2a6163f5eafe","unresolved":false,"context_lines":[{"line_number":357,"context_line":"  attempts to suspend the instance, the libvirt driver will raise an exception"},{"line_number":358,"context_line":"  that will cause the instance to be set back to ACTIVE. The ``suspend`` action"},{"line_number":359,"context_line":"  in the ``os-instance-actions`` API will have an *Error* state."},{"line_number":360,"context_line":""},{"line_number":361,"context_line":"* Resizing an instance with a new flavor that has vGPU resources doesn\u0027t"},{"line_number":362,"context_line":"  allocate those vGPUs to the instance (the instance is created without"},{"line_number":363,"context_line":"  vGPU resources). The proposed workaround is to rebuild the instance after"}],"source_content_type":"text/x-rst","patch_set":7,"id":"1f493fa4_21d62a51","line":360,"updated":"2020-04-20 17:21:29.000000000","message":"Prior to the 21.0.0 (Ussuri) release, the following caveats were also present. These have now been resolved.","commit_id":"d2e0afc1f72db5cb56ed987e2873798fc1e89545"}],"nova/tests/functional/integrated_helpers.py":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"b00ec2536a1d6f779f6edfd144e5a8c5360adc23","unresolved":false,"context_lines":[{"line_number":392,"context_line":"            \u0027instance.resize_revert.end\u0027)"},{"line_number":393,"context_line":"        return server"},{"line_number":394,"context_line":""},{"line_number":395,"context_line":"    def _migrate_or_resize(self, server, request):"},{"line_number":396,"context_line":"        if not (\u0027resize\u0027 in request or \u0027migrate\u0027 in request):"},{"line_number":397,"context_line":"            raise Exception(\u0027_migrate_or_resize only supports resize or \u0027"},{"line_number":398,"context_line":"                            \u0027migrate requests.\u0027)"},{"line_number":399,"context_line":"        self.api.post_server_action(server[\u0027id\u0027], request)"},{"line_number":400,"context_line":"        self._wait_for_state_change(server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":401,"context_line":""},{"line_number":402,"context_line":"    def _resize_server(self, server, new_flavor):"},{"line_number":403,"context_line":"        resize_req \u003d {"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f4c43b2_18fe726a","line":400,"range":{"start_line":395,"start_character":0,"end_line":400,"end_character":60},"updated":"2020-04-20 12:39:47.000000000","message":"I feel here we pushed the deduplication of the test code too far. But meh.","commit_id":"519f8e27430e9cf0f9e5504dc9009ca5d9065e35"}],"nova/tests/functional/libvirt/test_vgpu.py":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"05f4951c2378ea84838cd721cc885c58dd2fdcbb","unresolved":false,"context_lines":[{"line_number":37,"context_line":"    FAKE_LIBVIRT_VERSION \u003d 5000000"},{"line_number":38,"context_line":"    FAKE_QEMU_VERSION \u003d 3001000"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    current_host \u003d \u0027host1\u0027"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    def setUp(self):"},{"line_number":43,"context_line":"        super(VGPUTestBase, self).setUp()"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_90444f1d","line":40,"updated":"2020-04-16 14:59:09.000000000","message":"A comment above this would be helpful. I know you have it called out in setUp but one has to read down to find that. Also, should it be private?","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":37,"context_line":"    FAKE_LIBVIRT_VERSION \u003d 5000000"},{"line_number":38,"context_line":"    FAKE_QEMU_VERSION \u003d 3001000"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    current_host \u003d \u0027host1\u0027"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    def setUp(self):"},{"line_number":43,"context_line":"        super(VGPUTestBase, self).setUp()"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_ae72bc0f","line":40,"in_reply_to":"3f4c43b2_90444f1d","updated":"2020-04-17 16:03:04.000000000","message":"Done","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"5f04acb42beaad5f1a737a14a91c2c82de18f0db","unresolved":false,"context_lines":[{"line_number":68,"context_line":"            \u0027nova.virt.libvirt.LibvirtDriver._get_vgpu_type_per_pgpu\u0027,"},{"line_number":69,"context_line":"             new\u003dfake_get_vgpu_type_per_pgpu))"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"        # for the sake of resizing, we need to patch the two methods below"},{"line_number":72,"context_line":"        self.useFixture(fixtures.MockPatch("},{"line_number":73,"context_line":"            \u0027nova.virt.libvirt.LibvirtDriver._get_instance_disk_info\u0027,"},{"line_number":74,"context_line":"             return_value\u003d[]))"},{"line_number":75,"context_line":"        self.useFixture(fixtures.MockPatch(\u0027os.rename\u0027))"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"        self.context \u003d context.get_admin_context()"},{"line_number":78,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_f012f357","line":75,"range":{"start_line":71,"start_character":3,"end_line":75,"end_character":56},"updated":"2020-04-16 14:39:30.000000000","message":"in this context i guess that makes sense although we also could have done that for only the test that needed it.\n\ni dont think we ever want those to execute in a functionl test env with how our current test work so im fine with doing it here to save repeating it later.","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":68,"context_line":"            \u0027nova.virt.libvirt.LibvirtDriver._get_vgpu_type_per_pgpu\u0027,"},{"line_number":69,"context_line":"             new\u003dfake_get_vgpu_type_per_pgpu))"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"        # for the sake of resizing, we need to patch the two methods below"},{"line_number":72,"context_line":"        self.useFixture(fixtures.MockPatch("},{"line_number":73,"context_line":"            \u0027nova.virt.libvirt.LibvirtDriver._get_instance_disk_info\u0027,"},{"line_number":74,"context_line":"             return_value\u003d[]))"},{"line_number":75,"context_line":"        self.useFixture(fixtures.MockPatch(\u0027os.rename\u0027))"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"        self.context \u003d context.get_admin_context()"},{"line_number":78,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_4ea05844","line":75,"range":{"start_line":71,"start_character":3,"end_line":75,"end_character":56},"in_reply_to":"3f4c43b2_f012f357","updated":"2020-04-17 16:03:04.000000000","message":"I\u0027ll move it to the VGPUTests base class to be closer to the usage.","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"5f04acb42beaad5f1a737a14a91c2c82de18f0db","unresolved":false,"context_lines":[{"line_number":143,"context_line":"        self.flags("},{"line_number":144,"context_line":"            enabled_vgpu_types\u003dfakelibvirt.NVIDIA_11_VGPU_TYPE,"},{"line_number":145,"context_line":"            group\u003d\u0027devices\u0027)"},{"line_number":146,"context_line":"        self.compute1 \u003d self._start_compute_service(\u0027host1\u0027)"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":"    def assert_vgpu_usage_for_compute(self, compute, expected):"},{"line_number":149,"context_line":"        total_usage \u003d 0"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_9073afb1","line":146,"range":{"start_line":146,"start_character":52,"end_line":146,"end_character":59},"updated":"2020-04-16 14:39:30.000000000","message":"nit it might be nice to use self.current_host here instead but this is fine since the values match.","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":143,"context_line":"        self.flags("},{"line_number":144,"context_line":"            enabled_vgpu_types\u003dfakelibvirt.NVIDIA_11_VGPU_TYPE,"},{"line_number":145,"context_line":"            group\u003d\u0027devices\u0027)"},{"line_number":146,"context_line":"        self.compute1 \u003d self._start_compute_service(\u0027host1\u0027)"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":"    def assert_vgpu_usage_for_compute(self, compute, expected):"},{"line_number":149,"context_line":"        total_usage \u003d 0"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_ae8e3ccd","line":146,"range":{"start_line":146,"start_character":52,"end_line":146,"end_character":59},"in_reply_to":"3f4c43b2_9073afb1","updated":"2020-04-17 16:03:04.000000000","message":"Done","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"05f4951c2378ea84838cd721cc885c58dd2fdcbb","unresolved":false,"context_lines":[{"line_number":157,"context_line":"            parent_rp_name \u003d compute.host + \u0027_\u0027 + parent_name"},{"line_number":158,"context_line":"            parent_rp_uuid \u003d self._get_provider_uuid_by_name(parent_rp_name)"},{"line_number":159,"context_line":"            parent_usage \u003d self._get_provider_usages(parent_rp_uuid)"},{"line_number":160,"context_line":"            if orc.VGPU in parent_usage:"},{"line_number":161,"context_line":"                total_usage +\u003d parent_usage[orc.VGPU]"},{"line_number":162,"context_line":"        self.assertEqual(expected, len(mdevs))"},{"line_number":163,"context_line":"        self.assertEqual(expected, total_usage)"},{"line_number":164,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_10731f4f","line":161,"range":{"start_line":160,"start_character":0,"end_line":161,"end_character":53},"updated":"2020-04-16 14:59:09.000000000","message":"If this was unset, wouldn\u0027t it be an error?\n\nLater: ah, wait, it would be unset if the vGPU existed but simply was not used, right?","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":157,"context_line":"            parent_rp_name \u003d compute.host + \u0027_\u0027 + parent_name"},{"line_number":158,"context_line":"            parent_rp_uuid \u003d self._get_provider_uuid_by_name(parent_rp_name)"},{"line_number":159,"context_line":"            parent_usage \u003d self._get_provider_usages(parent_rp_uuid)"},{"line_number":160,"context_line":"            if orc.VGPU in parent_usage:"},{"line_number":161,"context_line":"                total_usage +\u003d parent_usage[orc.VGPU]"},{"line_number":162,"context_line":"        self.assertEqual(expected, len(mdevs))"},{"line_number":163,"context_line":"        self.assertEqual(expected, total_usage)"},{"line_number":164,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_e9315ea4","line":161,"range":{"start_line":160,"start_character":0,"end_line":161,"end_character":53},"in_reply_to":"3f4c43b2_10731f4f","updated":"2020-04-17 16:03:04.000000000","message":"No, in theory, we should only get a parent inventory that always contains a VGPU resource class since we create those inventories when we see a pGPU.\n\nThis being said, I prefer to be cautious and make sure that we doublecheck the resourceclass usage before getting it by its name.","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"05f4951c2378ea84838cd721cc885c58dd2fdcbb","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        self._create_server("},{"line_number":167,"context_line":"            image_uuid\u003d\u0027155d900f-4e14-4e4c-a73d-069cbf4541e6\u0027,"},{"line_number":168,"context_line":"            flavor_id\u003dself.flavor, host\u003dself.compute1.host,"},{"line_number":169,"context_line":"            networks\u003d\u0027auto\u0027, expected_state\u003d\u0027ACTIVE\u0027)"},{"line_number":170,"context_line":"        self.assert_vgpu_usage_for_compute(self.compute1, expected\u003d1)"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    def _resize_server(self, server, flavor):"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_b0998b6f","line":169,"range":{"start_line":169,"start_character":13,"end_line":169,"end_character":29},"updated":"2020-04-16 14:59:09.000000000","message":"because you changed the microversion, right?","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"5f04acb42beaad5f1a737a14a91c2c82de18f0db","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        self._create_server("},{"line_number":167,"context_line":"            image_uuid\u003d\u0027155d900f-4e14-4e4c-a73d-069cbf4541e6\u0027,"},{"line_number":168,"context_line":"            flavor_id\u003dself.flavor, host\u003dself.compute1.host,"},{"line_number":169,"context_line":"            networks\u003d\u0027auto\u0027, expected_state\u003d\u0027ACTIVE\u0027)"},{"line_number":170,"context_line":"        self.assert_vgpu_usage_for_compute(self.compute1, expected\u003d1)"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    def _resize_server(self, server, flavor):"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_f0ae73e5","line":169,"range":{"start_line":169,"start_character":11,"end_line":169,"end_character":29},"updated":"2020-04-16 14:39:30.000000000","message":"this seams unrealted to the vgpu changes.","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        self._create_server("},{"line_number":167,"context_line":"            image_uuid\u003d\u0027155d900f-4e14-4e4c-a73d-069cbf4541e6\u0027,"},{"line_number":168,"context_line":"            flavor_id\u003dself.flavor, host\u003dself.compute1.host,"},{"line_number":169,"context_line":"            networks\u003d\u0027auto\u0027, expected_state\u003d\u0027ACTIVE\u0027)"},{"line_number":170,"context_line":"        self.assert_vgpu_usage_for_compute(self.compute1, expected\u003d1)"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    def _resize_server(self, server, flavor):"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_691d4e0e","line":169,"range":{"start_line":169,"start_character":13,"end_line":169,"end_character":29},"in_reply_to":"3f4c43b2_b0998b6f","updated":"2020-04-17 16:03:04.000000000","message":"Indeed, the test now uses 2.74 which is newer than 2.37 (hence supporting it) which is \u0027Get Me a Network\u0027 which asks the networks parameter now [1]\n\n[1] https://docs.openstack.org/nova/latest/reference/api-microversion-history.html#id35","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"5f04acb42beaad5f1a737a14a91c2c82de18f0db","unresolved":false,"context_lines":[{"line_number":169,"context_line":"            networks\u003d\u0027auto\u0027, expected_state\u003d\u0027ACTIVE\u0027)"},{"line_number":170,"context_line":"        self.assert_vgpu_usage_for_compute(self.compute1, expected\u003d1)"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    def _resize_server(self, server, flavor):"},{"line_number":173,"context_line":"        resize_req \u003d {"},{"line_number":174,"context_line":"            \u0027resize\u0027: {"},{"line_number":175,"context_line":"                \u0027flavorRef\u0027: flavor"},{"line_number":176,"context_line":"            }"},{"line_number":177,"context_line":"        }"},{"line_number":178,"context_line":"        self.api.api_post(\u0027/servers/%s/action\u0027 % server[\u0027id\u0027],"},{"line_number":179,"context_line":"                          resize_req)"},{"line_number":180,"context_line":"        self._wait_for_state_change(server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"    def _confirm_resize(self, server, host\u003d\u0027host1\u0027):"},{"line_number":183,"context_line":"        confirm_resize_req \u003d {\u0027confirmResize\u0027: None}"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_f097938f","line":180,"range":{"start_line":172,"start_character":3,"end_line":180,"end_character":60},"updated":"2020-04-16 14:39:30.000000000","message":"you might want to consider using\n _resize_and_check_allocations form the intgreated helpers.\nor factoring out a _resize one\n\nhttps://github.com/openstack/nova/blob/e1359567e4985e9a671359d4c0d53404a8ba64ab/nova/tests/functional/integrated_helpers.py#L958-L968","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":169,"context_line":"            networks\u003d\u0027auto\u0027, expected_state\u003d\u0027ACTIVE\u0027)"},{"line_number":170,"context_line":"        self.assert_vgpu_usage_for_compute(self.compute1, expected\u003d1)"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    def _resize_server(self, server, flavor):"},{"line_number":173,"context_line":"        resize_req \u003d {"},{"line_number":174,"context_line":"            \u0027resize\u0027: {"},{"line_number":175,"context_line":"                \u0027flavorRef\u0027: flavor"},{"line_number":176,"context_line":"            }"},{"line_number":177,"context_line":"        }"},{"line_number":178,"context_line":"        self.api.api_post(\u0027/servers/%s/action\u0027 % server[\u0027id\u0027],"},{"line_number":179,"context_line":"                          resize_req)"},{"line_number":180,"context_line":"        self._wait_for_state_change(server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"    def _confirm_resize(self, server, host\u003d\u0027host1\u0027):"},{"line_number":183,"context_line":"        confirm_resize_req \u003d {\u0027confirmResize\u0027: None}"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_aa774502","line":180,"range":{"start_line":172,"start_character":3,"end_line":180,"end_character":60},"in_reply_to":"3f4c43b2_30773b05","updated":"2020-04-17 16:03:04.000000000","message":"Done","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"05f4951c2378ea84838cd721cc885c58dd2fdcbb","unresolved":false,"context_lines":[{"line_number":169,"context_line":"            networks\u003d\u0027auto\u0027, expected_state\u003d\u0027ACTIVE\u0027)"},{"line_number":170,"context_line":"        self.assert_vgpu_usage_for_compute(self.compute1, expected\u003d1)"},{"line_number":171,"context_line":""},{"line_number":172,"context_line":"    def _resize_server(self, server, flavor):"},{"line_number":173,"context_line":"        resize_req \u003d {"},{"line_number":174,"context_line":"            \u0027resize\u0027: {"},{"line_number":175,"context_line":"                \u0027flavorRef\u0027: flavor"},{"line_number":176,"context_line":"            }"},{"line_number":177,"context_line":"        }"},{"line_number":178,"context_line":"        self.api.api_post(\u0027/servers/%s/action\u0027 % server[\u0027id\u0027],"},{"line_number":179,"context_line":"                          resize_req)"},{"line_number":180,"context_line":"        self._wait_for_state_change(server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"    def _confirm_resize(self, server, host\u003d\u0027host1\u0027):"},{"line_number":183,"context_line":"        confirm_resize_req \u003d {\u0027confirmResize\u0027: None}"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_30773b05","line":180,"range":{"start_line":172,"start_character":3,"end_line":180,"end_character":60},"in_reply_to":"3f4c43b2_f097938f","updated":"2020-04-16 14:59:09.000000000","message":"Yeah, I want to see this whole file rewritten to make better use of those helpers, but I\u0027m willing to let that slide for now","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"05f4951c2378ea84838cd721cc885c58dd2fdcbb","unresolved":false,"context_lines":[{"line_number":179,"context_line":"                          resize_req)"},{"line_number":180,"context_line":"        self._wait_for_state_change(server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"    def _confirm_resize(self, server, host\u003d\u0027host1\u0027):"},{"line_number":183,"context_line":"        confirm_resize_req \u003d {\u0027confirmResize\u0027: None}"},{"line_number":184,"context_line":"        # NOTE(sbauza): Unfortunately, _cleanup_resize() in libvirt checks the"},{"line_number":185,"context_line":"        # host option to know the source hostname but given we have a global"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_b0d18bd0","line":182,"updated":"2020-04-16 14:59:09.000000000","message":"We have helpers for this already. Can you use them? [1]\n\n[1] https://github.com/openstack/nova/blob/20.1.0/nova/tests/functional/integrated_helpers.py#L938-L956","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":179,"context_line":"                          resize_req)"},{"line_number":180,"context_line":"        self._wait_for_state_change(server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"    def _confirm_resize(self, server, host\u003d\u0027host1\u0027):"},{"line_number":183,"context_line":"        confirm_resize_req \u003d {\u0027confirmResize\u0027: None}"},{"line_number":184,"context_line":"        # NOTE(sbauza): Unfortunately, _cleanup_resize() in libvirt checks the"},{"line_number":185,"context_line":"        # host option to know the source hostname but given we have a global"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_ea62ed3d","line":182,"in_reply_to":"3f4c43b2_b0d18bd0","updated":"2020-04-17 16:03:04.000000000","message":"Done","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"5f04acb42beaad5f1a737a14a91c2c82de18f0db","unresolved":false,"context_lines":[{"line_number":179,"context_line":"                          resize_req)"},{"line_number":180,"context_line":"        self._wait_for_state_change(server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"    def _confirm_resize(self, server, host\u003d\u0027host1\u0027):"},{"line_number":183,"context_line":"        confirm_resize_req \u003d {\u0027confirmResize\u0027: None}"},{"line_number":184,"context_line":"        # NOTE(sbauza): Unfortunately, _cleanup_resize() in libvirt checks the"},{"line_number":185,"context_line":"        # host option to know the source hostname but given we have a global"},{"line_number":186,"context_line":"        # CONF, the value will be the hostname of the last compute service that"},{"line_number":187,"context_line":"        # was created, so we need to change it here."},{"line_number":188,"context_line":"        # TODO(sbauza): Remove the below once we stop using CONF.host in"},{"line_number":189,"context_line":"        # libvirt and rather looking at the compute host value."},{"line_number":190,"context_line":"        orig_host \u003d CONF.host"},{"line_number":191,"context_line":"        self.flags(host\u003dhost)"},{"line_number":192,"context_line":"        self.api.api_post(\u0027/servers/%s/action\u0027 % server[\u0027id\u0027],"},{"line_number":193,"context_line":"                          confirm_resize_req)"},{"line_number":194,"context_line":"        self.flags(host\u003dorig_host)"},{"line_number":195,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"    def _revert_resize(self, server):"},{"line_number":198,"context_line":"        revert_resize_req \u003d {\u0027revertResize\u0027: None}"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_30929b9f","line":195,"range":{"start_line":182,"start_character":0,"end_line":195,"end_character":53},"updated":"2020-04-16 14:39:30.000000000","message":"this should use\n\nhttps://github.com/openstack/nova/blob/e1359567e4985e9a671359d4c0d53404a8ba64ab/nova/tests/functional/integrated_helpers.py#L1049-L1055\n\nthis version has a race since it does not also wait for a notification or instance action event.\n\ngibi pointed this out in the past when reviewing one of the regression tests i wrote pointing out that waiting for state change is not enough.\n\nthe integrated helper version does it correctly.\n\nalso im not sure about set host as we dont need to do that for our other resize functional and regression tests.","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":179,"context_line":"                          resize_req)"},{"line_number":180,"context_line":"        self._wait_for_state_change(server, \u0027VERIFY_RESIZE\u0027)"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"    def _confirm_resize(self, server, host\u003d\u0027host1\u0027):"},{"line_number":183,"context_line":"        confirm_resize_req \u003d {\u0027confirmResize\u0027: None}"},{"line_number":184,"context_line":"        # NOTE(sbauza): Unfortunately, _cleanup_resize() in libvirt checks the"},{"line_number":185,"context_line":"        # host option to know the source hostname but given we have a global"},{"line_number":186,"context_line":"        # CONF, the value will be the hostname of the last compute service that"},{"line_number":187,"context_line":"        # was created, so we need to change it here."},{"line_number":188,"context_line":"        # TODO(sbauza): Remove the below once we stop using CONF.host in"},{"line_number":189,"context_line":"        # libvirt and rather looking at the compute host value."},{"line_number":190,"context_line":"        orig_host \u003d CONF.host"},{"line_number":191,"context_line":"        self.flags(host\u003dhost)"},{"line_number":192,"context_line":"        self.api.api_post(\u0027/servers/%s/action\u0027 % server[\u0027id\u0027],"},{"line_number":193,"context_line":"                          confirm_resize_req)"},{"line_number":194,"context_line":"        self.flags(host\u003dorig_host)"},{"line_number":195,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"    def _revert_resize(self, server):"},{"line_number":198,"context_line":"        revert_resize_req \u003d {\u0027revertResize\u0027: None}"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_ca657147","line":195,"range":{"start_line":182,"start_character":0,"end_line":195,"end_character":53},"in_reply_to":"3f4c43b2_30929b9f","updated":"2020-04-17 16:03:04.000000000","message":"Done","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"05f4951c2378ea84838cd721cc885c58dd2fdcbb","unresolved":false,"context_lines":[{"line_number":195,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"    def _revert_resize(self, server):"},{"line_number":198,"context_line":"        revert_resize_req \u003d {\u0027revertResize\u0027: None}"},{"line_number":199,"context_line":"        self.api.api_post(\u0027/servers/%s/action\u0027 % server[\u0027id\u0027],"},{"line_number":200,"context_line":"                          revert_resize_req)"},{"line_number":201,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_d0f4178a","line":198,"updated":"2020-04-16 14:59:09.000000000","message":"nit: could you move this into the api_post call?","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":195,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"    def _revert_resize(self, server):"},{"line_number":198,"context_line":"        revert_resize_req \u003d {\u0027revertResize\u0027: None}"},{"line_number":199,"context_line":"        self.api.api_post(\u0027/servers/%s/action\u0027 % server[\u0027id\u0027],"},{"line_number":200,"context_line":"                          revert_resize_req)"},{"line_number":201,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_4a516162","line":198,"in_reply_to":"3f4c43b2_d0f4178a","updated":"2020-04-17 16:03:04.000000000","message":"Done","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"5f04acb42beaad5f1a737a14a91c2c82de18f0db","unresolved":false,"context_lines":[{"line_number":194,"context_line":"        self.flags(host\u003dorig_host)"},{"line_number":195,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"    def _revert_resize(self, server):"},{"line_number":198,"context_line":"        revert_resize_req \u003d {\u0027revertResize\u0027: None}"},{"line_number":199,"context_line":"        self.api.api_post(\u0027/servers/%s/action\u0027 % server[\u0027id\u0027],"},{"line_number":200,"context_line":"                          revert_resize_req)"},{"line_number":201,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"    def test_resize_servers_with_vgpu(self):"},{"line_number":204,"context_line":"        # Add another compute for the sake of resizing"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_30e73b43","line":201,"range":{"start_line":197,"start_character":3,"end_line":201,"end_character":53},"updated":"2020-04-16 14:39:30.000000000","message":"and this should use\n\nhttps://github.com/openstack/nova/blob/e1359567e4985e9a671359d4c0d53404a8ba64ab/nova/tests/functional/integrated_helpers.py#L1057-L1067\n\nnow that we have them in the integrated helpers we should stop adding duplicates in the different funcational tests.\n\nit also use the fake_notifer to wait for the  revert to complete fully.","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":194,"context_line":"        self.flags(host\u003dorig_host)"},{"line_number":195,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"    def _revert_resize(self, server):"},{"line_number":198,"context_line":"        revert_resize_req \u003d {\u0027revertResize\u0027: None}"},{"line_number":199,"context_line":"        self.api.api_post(\u0027/servers/%s/action\u0027 % server[\u0027id\u0027],"},{"line_number":200,"context_line":"                          revert_resize_req)"},{"line_number":201,"context_line":"        self._wait_for_state_change(server, \u0027ACTIVE\u0027)"},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"    def test_resize_servers_with_vgpu(self):"},{"line_number":204,"context_line":"        # Add another compute for the sake of resizing"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_0a60f931","line":201,"range":{"start_line":197,"start_character":3,"end_line":201,"end_character":53},"in_reply_to":"3f4c43b2_30e73b43","updated":"2020-04-17 16:03:04.000000000","message":"Done","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"05f4951c2378ea84838cd721cc885c58dd2fdcbb","unresolved":false,"context_lines":[{"line_number":213,"context_line":""},{"line_number":214,"context_line":"        extra_spec \u003d {\"resources:VGPU\": \"1\"}"},{"line_number":215,"context_line":"        new_flavor \u003d self._create_flavor(memory_mb\u003d4096,"},{"line_number":216,"context_line":"                                            extra_spec\u003dextra_spec)"},{"line_number":217,"context_line":"        # First, resize and then revert."},{"line_number":218,"context_line":"        self._resize_server(server, new_flavor)"},{"line_number":219,"context_line":"        # After resizing, we then have two vGPUs, both for each compute"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_701423a1","line":216,"range":{"start_line":216,"start_character":41,"end_line":216,"end_character":44},"updated":"2020-04-16 14:59:09.000000000","message":"nit","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"645d8e4ec3aca97ee788cf3a0739cf1c369fd358","unresolved":false,"context_lines":[{"line_number":213,"context_line":""},{"line_number":214,"context_line":"        extra_spec \u003d {\"resources:VGPU\": \"1\"}"},{"line_number":215,"context_line":"        new_flavor \u003d self._create_flavor(memory_mb\u003d4096,"},{"line_number":216,"context_line":"                                            extra_spec\u003dextra_spec)"},{"line_number":217,"context_line":"        # First, resize and then revert."},{"line_number":218,"context_line":"        self._resize_server(server, new_flavor)"},{"line_number":219,"context_line":"        # After resizing, we then have two vGPUs, both for each compute"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_aa50e55e","line":216,"range":{"start_line":216,"start_character":41,"end_line":216,"end_character":44},"in_reply_to":"3f4c43b2_701423a1","updated":"2020-04-17 16:03:04.000000000","message":"Done","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"b00ec2536a1d6f779f6edfd144e5a8c5360adc23","unresolved":false,"context_lines":[{"line_number":42,"context_line":""},{"line_number":43,"context_line":"    # Since we run all computes by a single process, we need to identify which"},{"line_number":44,"context_line":"    # current compute service we use at the moment."},{"line_number":45,"context_line":"    _current_host \u003d _DEFAULT_HOST"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"    def setUp(self):"},{"line_number":48,"context_line":"        super(VGPUTestBase, self).setUp()"}],"source_content_type":"text/x-python","patch_set":6,"id":"3f4c43b2_de0b53d3","line":45,"updated":"2020-04-20 12:39:47.000000000","message":"This might leak information between test cases in the same test object instantiated from VGPUTests class. Assuming a single test executor. I think the test runner will instantiate a single VGPUTests object and run both test cases on the same object (but calling setUp before each test case).\n\nI\u0027m not 100% sure you always set the value first in a test case then using that value later.","commit_id":"519f8e27430e9cf0f9e5504dc9009ca5d9065e35"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"3affeec8375b345874f16235cb5fe8b690dde127","unresolved":false,"context_lines":[{"line_number":10109,"context_line":"                self._disk_raw_to_qcow2(info[\u0027path\u0027])"},{"line_number":10110,"context_line":""},{"line_number":10111,"context_line":"        # Does the guest need to be assigned some vGPU mediated devices ?"},{"line_number":10112,"context_line":"        mdevs \u003d self._allocate_mdevs(allocations)"},{"line_number":10113,"context_line":""},{"line_number":10114,"context_line":"        xml \u003d self._get_guest_xml(context, instance, network_info,"},{"line_number":10115,"context_line":"                                  block_disk_info, image_meta,"}],"source_content_type":"text/x-python","patch_set":2,"id":"3f4c43b2_e1b18791","line":10112,"updated":"2020-04-16 17:17:42.000000000","message":"Dan (Smith) made a very good comment on IRC on the fact we could run out of mdevs here since we\u0027re allocating a new mdev instead of reusing the existing one.\n\nWill provide a new revision\n\nhttp://eavesdrop.openstack.org/irclogs/%23openstack-nova/%23openstack-nova.2020-04-16.log.html#t2020-04-16T17:12:05","commit_id":"3c940e2a2dd74b8f33a3e8eb3478b7985c7b0a09"}]}
