)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"a818baaba606e500f0322931fd481f6d968a711c","unresolved":false,"context_lines":[{"line_number":34,"context_line":"the handle-default-machine-type-as-q35 blueprint."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"blueprint: amd-sev-libvirt-support"},{"line_number":37,"context_line":"blueprint: handle-default-machine-type-as-q35"},{"line_number":38,"context_line":"Change-Id: I4c35b6a27db05349213429422ffe62adb09bd921"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":11,"id":"5fc1f717_55617204","line":37,"range":{"start_line":37,"start_character":11,"end_line":37,"end_character":45},"updated":"2019-03-14 08:45:40.000000000","message":"Consider removing the reference to the machine types blueprint here, as it can be confusing to some.","commit_id":"55ae1740e33f8506f0a7f6e380538f2062aea2f4"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"674df0392370704a8443f57f8dc021b0b5fc5b69","unresolved":false,"context_lines":[{"line_number":34,"context_line":"the handle-default-machine-type-as-q35 blueprint."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"blueprint: amd-sev-libvirt-support"},{"line_number":37,"context_line":"blueprint: handle-default-machine-type-as-q35"},{"line_number":38,"context_line":"Change-Id: I4c35b6a27db05349213429422ffe62adb09bd921"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":11,"id":"5fc1f717_65cfc1b0","line":37,"range":{"start_line":37,"start_character":11,"end_line":37,"end_character":45},"in_reply_to":"5fc1f717_55617204","updated":"2019-03-19 13:54:02.000000000","message":"Really? It\u0027s explained in the paragraph immediately above - what confusion are you anticipating?","commit_id":"55ae1740e33f8506f0a7f6e380538f2062aea2f4"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"4f1b7cfdfa29eaaa9530e5c3456b864d03fa18b4","unresolved":false,"context_lines":[{"line_number":34,"context_line":"the handle-default-machine-type-as-q35 blueprint."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"blueprint: amd-sev-libvirt-support"},{"line_number":37,"context_line":"blueprint: handle-default-machine-type-as-q35"},{"line_number":38,"context_line":"Change-Id: I4c35b6a27db05349213429422ffe62adb09bd921"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"5fc1f717_4fbb6dc3","line":37,"range":{"start_line":37,"start_character":0,"end_line":37,"end_character":45},"updated":"2019-03-22 16:13:44.000000000","message":"I couldn\u0027t find this blueprint. What gives?","commit_id":"b375e1ed93dc1ce6b6a681b27156aaa9b2a98ca4"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"19033fed9dbc89ff91ac5b90aa7bcc0495be1fcb","unresolved":false,"context_lines":[{"line_number":34,"context_line":"the handle-default-machine-type-as-q35 blueprint."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"blueprint: amd-sev-libvirt-support"},{"line_number":37,"context_line":"blueprint: handle-default-machine-type-as-q35"},{"line_number":38,"context_line":"Change-Id: I4c35b6a27db05349213429422ffe62adb09bd921"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"ffb9cba7_8f40a037","line":37,"range":{"start_line":37,"start_character":0,"end_line":37,"end_character":45},"in_reply_to":"5fc1f717_24dd92dc","updated":"2019-04-23 23:30:27.000000000","message":"Since I split out the introduction of getDomainCapabilities into a separate review, this is no longer needed here.","commit_id":"b375e1ed93dc1ce6b6a681b27156aaa9b2a98ca4"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"cfe65ae4e519fba72b427215adc096f656909a7f","unresolved":false,"context_lines":[{"line_number":34,"context_line":"the handle-default-machine-type-as-q35 blueprint."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"blueprint: amd-sev-libvirt-support"},{"line_number":37,"context_line":"blueprint: handle-default-machine-type-as-q35"},{"line_number":38,"context_line":"Change-Id: I4c35b6a27db05349213429422ffe62adb09bd921"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"5fc1f717_6308c2d8","line":37,"range":{"start_line":37,"start_character":0,"end_line":37,"end_character":45},"in_reply_to":"5fc1f717_4fbb6dc3","updated":"2019-03-22 18:01:37.000000000","message":"Kashyap renamed it.  I\u0027ll update in the next patchset.","commit_id":"b375e1ed93dc1ce6b6a681b27156aaa9b2a98ca4"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"0b271c3850f44fd1ea2df4599ae3e67a51dec216","unresolved":false,"context_lines":[{"line_number":34,"context_line":"the handle-default-machine-type-as-q35 blueprint."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"blueprint: amd-sev-libvirt-support"},{"line_number":37,"context_line":"blueprint: handle-default-machine-type-as-q35"},{"line_number":38,"context_line":"Change-Id: I4c35b6a27db05349213429422ffe62adb09bd921"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"5fc1f717_24dd92dc","line":37,"range":{"start_line":37,"start_character":0,"end_line":37,"end_character":45},"in_reply_to":"5fc1f717_6308c2d8","updated":"2019-04-09 10:32:13.000000000","message":"Yeah, sorry: the new name is: `gracefully-handle-qemu-machine-types`[1].\n\nBackground for why I changed the name: When I originally filed the blueprint, there was active discussion on upstream QEMU devel list whether to change the default to Q35.  Now they decided against it (for the time being), and let management tools adopt it.\n\nSo I updated the blueprint\u0027s name to reflect the new reality.\n\n[1] https://blueprints.launchpad.net/nova/+spec/gracefully-handle-qemu-machine-types","commit_id":"b375e1ed93dc1ce6b6a681b27156aaa9b2a98ca4"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"67d6b15a8986e582790726a45b29367f86121dee","unresolved":false,"context_lines":[{"line_number":26,"context_line":""},{"line_number":27,"context_line":"This commit addresses the second of these two checks.  Subsequent"},{"line_number":28,"context_line":"commits will address the first, add logic which combines both checks"},{"line_number":29,"context_line":"and provides a new standard trait which indicates that both checks"},{"line_number":30,"context_line":"have passed, and of course ultimately make use of that new trait."},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"blueprint: amd-sev-libvirt-support"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":14,"id":"bfb3d3c7_a3bdaa69","line":29,"range":{"start_line":29,"start_character":4,"end_line":29,"end_character":12},"updated":"2019-05-17 17:50:17.000000000","message":"provide","commit_id":"82be453d1358c41930d3066f670dbb91893b4035"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"c89a69ecaec6b5ea89c69418a6243c99116814f4","unresolved":false,"context_lines":[{"line_number":26,"context_line":""},{"line_number":27,"context_line":"This commit addresses the second of these two checks.  Subsequent"},{"line_number":28,"context_line":"commits will address the first, add logic which combines both checks"},{"line_number":29,"context_line":"and provides a new standard trait which indicates that both checks"},{"line_number":30,"context_line":"have passed, and of course ultimately make use of that new trait."},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"blueprint: amd-sev-libvirt-support"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":14,"id":"bfb3d3c7_0e5ffd41","line":29,"range":{"start_line":29,"start_character":4,"end_line":29,"end_character":12},"in_reply_to":"bfb3d3c7_a3bdaa69","updated":"2019-05-17 18:46:47.000000000","message":"Done","commit_id":"82be453d1358c41930d3066f670dbb91893b4035"}],"nova/tests/unit/virt/libvirt/fakelibvirt.py":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"2e109237ee7db5e448115989c940a4341f65c6ba","unresolved":false,"context_lines":[{"line_number":1515,"context_line":""},{"line_number":1516,"context_line":"    _domain_capability_features_with_SEV_unsupported \u003d \\"},{"line_number":1517,"context_line":"        _domain_capability_features_with_SEV.replace(\u0027yes\u0027, \u0027no\u0027)"},{"line_number":1518,"context_line":""},{"line_number":1519,"context_line":"    def getCapabilities(self):"},{"line_number":1520,"context_line":"        \"\"\"Return spoofed capabilities.\"\"\""},{"line_number":1521,"context_line":"        numa_topology \u003d self.host_info.numa_topology"}],"source_content_type":"text/x-python","patch_set":15,"id":"bfb3d3c7_91b1a592","line":1518,"updated":"2019-05-21 10:34:57.000000000","message":"Something about how this is being done feels wrong to me, but I don\u0027t have a clever idea","commit_id":"434e30f0d2f79a1f5700ae2aef1658708ff02d17"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"56178c727d714c4351b50685a989fd4e354636e0","unresolved":false,"context_lines":[{"line_number":1515,"context_line":""},{"line_number":1516,"context_line":"    _domain_capability_features_with_SEV_unsupported \u003d \\"},{"line_number":1517,"context_line":"        _domain_capability_features_with_SEV.replace(\u0027yes\u0027, \u0027no\u0027)"},{"line_number":1518,"context_line":""},{"line_number":1519,"context_line":"    def getCapabilities(self):"},{"line_number":1520,"context_line":"        \"\"\"Return spoofed capabilities.\"\"\""},{"line_number":1521,"context_line":"        numa_topology \u003d self.host_info.numa_topology"}],"source_content_type":"text/x-python","patch_set":15,"id":"bfb3d3c7_5341ee0a","line":1518,"in_reply_to":"bfb3d3c7_8cdc2e75","updated":"2019-05-21 13:58:11.000000000","message":"Yeah, I can live with it, though.  Unless you really insist it be reworked that way :-)","commit_id":"434e30f0d2f79a1f5700ae2aef1658708ff02d17"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"12022e0a2a6bf7a7d7a82c461a84a7212cd6d6aa","unresolved":false,"context_lines":[{"line_number":1515,"context_line":""},{"line_number":1516,"context_line":"    _domain_capability_features_with_SEV_unsupported \u003d \\"},{"line_number":1517,"context_line":"        _domain_capability_features_with_SEV.replace(\u0027yes\u0027, \u0027no\u0027)"},{"line_number":1518,"context_line":""},{"line_number":1519,"context_line":"    def getCapabilities(self):"},{"line_number":1520,"context_line":"        \"\"\"Return spoofed capabilities.\"\"\""},{"line_number":1521,"context_line":"        numa_topology \u003d self.host_info.numa_topology"}],"source_content_type":"text/x-python","patch_set":15,"id":"bfb3d3c7_8cdc2e75","line":1518,"in_reply_to":"bfb3d3c7_91b1a592","updated":"2019-05-21 10:59:48.000000000","message":"you dislike the use of \\\n\nwe coudl do \n\ntemplate \u003d \"\"\"\n  \u003cfeatures\u003e\n    \u003cgic supported\u003d\u0027no\u0027/\u003e\n    \u003csev supported\u003d\u0027%s\u0027\u003e\n      \u003ccbitpos\u003e47\u003c/cbitpos\u003e\n      \u003creducedPhysBits\u003e1\u003c/reducedPhysBits\u003e\n    \u003c/sev\u003e\n  \u003c/features\u003e\"\"\"\n\n_domain_capability_features_with_SEV \u003d template % \u0027yes\u0027\n_domain_capability_features_with_SEV_unsupported \u003d template % \u0027no\u0027","commit_id":"434e30f0d2f79a1f5700ae2aef1658708ff02d17"}],"nova/tests/unit/virt/libvirt/test_host.py":[{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"ef7eb31d2682aa92ee02e00738a1f630c6ae3a4d","unresolved":false,"context_lines":[{"line_number":684,"context_line":"        self.assertEqual(1, len(features))"},{"line_number":685,"context_line":"        sev \u003d features[0]"},{"line_number":686,"context_line":"        self.assertEqual(vconfig.LibvirtConfigDomainCapsFeatureSev, type(sev))"},{"line_number":687,"context_line":"        self.assertTrue(sev.supported)"},{"line_number":688,"context_line":""},{"line_number":689,"context_line":"    @mock.patch.object(fakelibvirt.virConnect, \"getHostname\")"},{"line_number":690,"context_line":"    def test_get_hostname_caching(self, mock_hostname):"}],"source_content_type":"text/x-python","patch_set":7,"id":"9fdfeff1_325f9876","line":687,"updated":"2019-03-05 14:54:18.000000000","message":"according to the commit message, there is a third possibility: that of QEMU not supporting sev feature but libvirt reporting the feature as \u003csev supported\u003d\u0027no\u0027\u003e. Is that scenario tested?","commit_id":"02b018edd8317b7f8dc02a78a6f76ff963d511d2"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"0f7fae9a9cb3bd0d07506ea1c5815556712943a3","unresolved":false,"context_lines":[{"line_number":684,"context_line":"        self.assertEqual(1, len(features))"},{"line_number":685,"context_line":"        sev \u003d features[0]"},{"line_number":686,"context_line":"        self.assertEqual(vconfig.LibvirtConfigDomainCapsFeatureSev, type(sev))"},{"line_number":687,"context_line":"        self.assertTrue(sev.supported)"},{"line_number":688,"context_line":""},{"line_number":689,"context_line":"    @mock.patch.object(fakelibvirt.virConnect, \"getHostname\")"},{"line_number":690,"context_line":"    def test_get_hostname_caching(self, mock_hostname):"}],"source_content_type":"text/x-python","patch_set":7,"id":"5fc1f717_61b7beda","line":687,"in_reply_to":"9fdfeff1_325f9876","updated":"2019-03-05 20:47:12.000000000","message":"Great catch!  Added.","commit_id":"02b018edd8317b7f8dc02a78a6f76ff963d511d2"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"67d6b15a8986e582790726a45b29367f86121dee","unresolved":false,"context_lines":[{"line_number":679,"context_line":"        new\u003dfakelibvirt.virConnect._domain_capability_features_with_SEV)"},{"line_number":680,"context_line":"    def test_get_domain_capabilities_sev_supported(self):"},{"line_number":681,"context_line":"        self._test_get_domain_capabilities_sev(True)"},{"line_number":682,"context_line":""},{"line_number":683,"context_line":"    @mock.patch.object(fakelibvirt.virConnect, \"getHostname\")"},{"line_number":684,"context_line":"    def test_get_hostname_caching(self, mock_hostname):"},{"line_number":685,"context_line":"        mock_hostname.return_value \u003d \"foo\""}],"source_content_type":"text/x-python","patch_set":14,"id":"bfb3d3c7_a34b6a85","line":682,"updated":"2019-05-17 17:50:17.000000000","message":"✔","commit_id":"82be453d1358c41930d3066f670dbb91893b4035"}],"nova/virt/libvirt/config.py":[{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"bee296176165164c4cdd2c8ceea9ff01af2dc1e5","unresolved":false,"context_lines":[{"line_number":138,"context_line":"    def __init__(self, **kwargs):"},{"line_number":139,"context_line":"        super(LibvirtConfigDomainCapsFeatures, self).__init__("},{"line_number":140,"context_line":"            root_name\u003d\"features\", **kwargs)"},{"line_number":141,"context_line":"        self.features \u003d []"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    def parse_dom(self, xmldoc):"},{"line_number":144,"context_line":"        super(LibvirtConfigDomainCapsFeatures, self).parse_dom(xmldoc)"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_0b59a333","line":141,"updated":"2019-02-12 18:55:42.000000000","message":"what do you think about switching from list to dict of {feature_tag: feature}? It would be more intuitive and readble to access caps.feature[\"sev\"] rather than caps.feature[0].","commit_id":"bbbb839c5ce6854f93f769edcddd19fe10474d6a"},{"author":{"_account_id":24938,"name":"Bryan Stephenson","email":"bryan.stephenson@suse.com","username":"bryans"},"change_message_id":"0fab019802a6b7563e53378524e6cf8952544e74","unresolved":false,"context_lines":[{"line_number":138,"context_line":"    def __init__(self, **kwargs):"},{"line_number":139,"context_line":"        super(LibvirtConfigDomainCapsFeatures, self).__init__("},{"line_number":140,"context_line":"            root_name\u003d\"features\", **kwargs)"},{"line_number":141,"context_line":"        self.features \u003d []"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    def parse_dom(self, xmldoc):"},{"line_number":144,"context_line":"        super(LibvirtConfigDomainCapsFeatures, self).parse_dom(xmldoc)"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_a6b20e93","line":141,"in_reply_to":"9fdfeff1_0b59a333","updated":"2019-02-12 20:21:01.000000000","message":"I think that is a good idea.","commit_id":"bbbb839c5ce6854f93f769edcddd19fe10474d6a"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"797c1371d5ae16b97b13810ad75776d0deb238ca","unresolved":false,"context_lines":[{"line_number":138,"context_line":"    def __init__(self, **kwargs):"},{"line_number":139,"context_line":"        super(LibvirtConfigDomainCapsFeatures, self).__init__("},{"line_number":140,"context_line":"            root_name\u003d\"features\", **kwargs)"},{"line_number":141,"context_line":"        self.features \u003d []"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    def parse_dom(self, xmldoc):"},{"line_number":144,"context_line":"        super(LibvirtConfigDomainCapsFeatures, self).parse_dom(xmldoc)"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_3098eb19","line":141,"in_reply_to":"9fdfeff1_0b59a333","updated":"2019-02-21 00:24:47.000000000","message":"Possibly ... I\u0027m not sure.  I was thinking that the intent of these classes is to represent the structure of the XML as closely as possible, and in that sense \u003cfeatures\u003e is an ordered list.  Switching to a dict loses the possibility of reliably preserving order of features between invocations of format_dom(), which could feasibly be a useful characteristic we don\u0027t want to lose.","commit_id":"bbbb839c5ce6854f93f769edcddd19fe10474d6a"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"4ad8ff7749cd5f05116023cd3b9dbff1eefa0d56","unresolved":false,"context_lines":[{"line_number":161,"context_line":"    # For the same reason, we do not need a format_dom() method, but"},{"line_number":162,"context_line":"    # it\u0027s a bug if this ever gets called and we inherited one from"},{"line_number":163,"context_line":"    # the base class, so override that to watch out for accidental"},{"line_number":164,"context_line":"    # calls."},{"line_number":165,"context_line":"    def format_dom(self):"},{"line_number":166,"context_line":"        raise RuntimeError(_(\u0027BUG: tried to generate domainCapabilities XML\u0027))"},{"line_number":167,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"9fdfeff1_372baeeb","line":164,"updated":"2019-03-06 22:51:51.000000000","message":"++","commit_id":"d9e9f25ce747ed15f82f3799d032ae9804a0b9fc"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"2e109237ee7db5e448115989c940a4341f65c6ba","unresolved":false,"context_lines":[{"line_number":176,"context_line":"        super(LibvirtConfigDomainCapsFeature, self).parse_dom(xmldoc)"},{"line_number":177,"context_line":""},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"class LibvirtConfigDomainCapsFeatureSev(LibvirtConfigDomainCapsFeature):"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    def __init__(self, **kwargs):"},{"line_number":182,"context_line":"        super(LibvirtConfigDomainCapsFeatureSev, self).__init__(\u0027sev\u0027,"}],"source_content_type":"text/x-python","patch_set":7,"id":"9fdfeff1_4ac88455","line":179,"range":{"start_line":179,"start_character":36,"end_line":179,"end_character":39},"updated":"2019-05-21 10:34:57.000000000","message":"SEV","commit_id":"02b018edd8317b7f8dc02a78a6f76ff963d511d2"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"e4046583398b74e3e3f907078c81bc0ee73fc571","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        raise RuntimeError(_(\u0027BUG: tried to generate domainCapabilities XML\u0027))"},{"line_number":167,"context_line":""},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"class LibvirtConfigDomainCapsFeature(LibvirtConfigObject):"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"    def __init__(self, name, **kwargs):"},{"line_number":172,"context_line":"        super(LibvirtConfigDomainCapsFeature, self).__init__(root_name\u003dname,"},{"line_number":173,"context_line":"                                                             **kwargs)"},{"line_number":174,"context_line":""},{"line_number":175,"context_line":"    def parse_dom(self, xmldoc):"},{"line_number":176,"context_line":"        super(LibvirtConfigDomainCapsFeature, self).parse_dom(xmldoc)"},{"line_number":177,"context_line":""},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"class LibvirtConfigDomainCapsFeatureSev(LibvirtConfigDomainCapsFeature):"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    def __init__(self, **kwargs):"},{"line_number":182,"context_line":"        super(LibvirtConfigDomainCapsFeatureSev, self).__init__(\u0027sev\u0027,"},{"line_number":183,"context_line":"                                                                **kwargs)"},{"line_number":184,"context_line":"        self.supported \u003d False"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"    def parse_dom(self, xmldoc):"}],"source_content_type":"text/x-python","patch_set":13,"id":"bfb3d3c7_74620d19","line":183,"range":{"start_line":169,"start_character":0,"end_line":183,"end_character":73},"updated":"2019-05-17 14:30:05.000000000","message":"Yeah, LibvirtConfigDomainCapsFeature seems unnecessary; this whole thing could just be\n\n class LibvirtConfigDomainCapsFeatureSev(LibvirtConfigObject):\n     def __init__(self, **kwargs):\n         super(LibvirtConfigDomainCapsFeatureSev, self).__init__(\n             root_name\u003d\u0027sev\u0027, **kwargs)","commit_id":"fc7b7e52150797ba12c72f429fe2618f61234c91"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"cd1c7bace29882e5462a6f3aeaf5cd4b97b60a33","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        raise RuntimeError(_(\u0027BUG: tried to generate domainCapabilities XML\u0027))"},{"line_number":167,"context_line":""},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"class LibvirtConfigDomainCapsFeature(LibvirtConfigObject):"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"    def __init__(self, name, **kwargs):"},{"line_number":172,"context_line":"        super(LibvirtConfigDomainCapsFeature, self).__init__(root_name\u003dname,"},{"line_number":173,"context_line":"                                                             **kwargs)"},{"line_number":174,"context_line":""},{"line_number":175,"context_line":"    def parse_dom(self, xmldoc):"},{"line_number":176,"context_line":"        super(LibvirtConfigDomainCapsFeature, self).parse_dom(xmldoc)"},{"line_number":177,"context_line":""},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"class LibvirtConfigDomainCapsFeatureSev(LibvirtConfigDomainCapsFeature):"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    def __init__(self, **kwargs):"},{"line_number":182,"context_line":"        super(LibvirtConfigDomainCapsFeatureSev, self).__init__(\u0027sev\u0027,"},{"line_number":183,"context_line":"                                                                **kwargs)"},{"line_number":184,"context_line":"        self.supported \u003d False"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"    def parse_dom(self, xmldoc):"}],"source_content_type":"text/x-python","patch_set":13,"id":"bfb3d3c7_c33bfe99","line":183,"range":{"start_line":169,"start_character":0,"end_line":183,"end_character":73},"in_reply_to":"bfb3d3c7_74620d19","updated":"2019-05-17 17:16:02.000000000","message":"Yeah fair enough, I was just copying the existing LibvirtConfigGuestFeature hierarchy for consistency - I\u0027ll get rid of it.","commit_id":"fc7b7e52150797ba12c72f429fe2618f61234c91"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"07ecb770610d6525a659cbb0e42112b3a64a0626","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        raise RuntimeError(_(\u0027BUG: tried to generate domainCapabilities XML\u0027))"},{"line_number":167,"context_line":""},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"class LibvirtConfigDomainCapsFeature(LibvirtConfigObject):"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"    def __init__(self, name, **kwargs):"},{"line_number":172,"context_line":"        super(LibvirtConfigDomainCapsFeature, self).__init__(root_name\u003dname,"},{"line_number":173,"context_line":"                                                             **kwargs)"},{"line_number":174,"context_line":""},{"line_number":175,"context_line":"    def parse_dom(self, xmldoc):"},{"line_number":176,"context_line":"        super(LibvirtConfigDomainCapsFeature, self).parse_dom(xmldoc)"},{"line_number":177,"context_line":""},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"class LibvirtConfigDomainCapsFeatureSev(LibvirtConfigDomainCapsFeature):"},{"line_number":180,"context_line":""},{"line_number":181,"context_line":"    def __init__(self, **kwargs):"},{"line_number":182,"context_line":"        super(LibvirtConfigDomainCapsFeatureSev, self).__init__(\u0027sev\u0027,"},{"line_number":183,"context_line":"                                                                **kwargs)"},{"line_number":184,"context_line":"        self.supported \u003d False"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"    def parse_dom(self, xmldoc):"}],"source_content_type":"text/x-python","patch_set":13,"id":"bfb3d3c7_23a21a9c","line":183,"range":{"start_line":169,"start_character":0,"end_line":183,"end_character":73},"in_reply_to":"bfb3d3c7_c33bfe99","updated":"2019-05-17 17:25:53.000000000","message":"Yeah, that one\u0027s worthless too. Removing it (and a couple others) in https://review.opendev.org/659848","commit_id":"fc7b7e52150797ba12c72f429fe2618f61234c91"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"67d6b15a8986e582790726a45b29367f86121dee","unresolved":false,"context_lines":[{"line_number":176,"context_line":"    def parse_dom(self, xmldoc):"},{"line_number":177,"context_line":"        super(LibvirtConfigDomainCapsFeatureSev, self).parse_dom(xmldoc)"},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"        if xmldoc.get(\u0027supported\u0027) \u003d\u003d \u0027yes\u0027:"},{"line_number":180,"context_line":"            self.supported \u003d True"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"bfb3d3c7_c3353ef9","line":179,"updated":"2019-05-17 17:50:17.000000000","message":"or\n\n self.supported \u003d xmldoc.get(\u0027supported\u0027) \u003d\u003d \u0027yes\u0027\n\nbut this is good","commit_id":"82be453d1358c41930d3066f670dbb91893b4035"}],"nova/virt/libvirt/host.py":[{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"7f764fe9aed2d8d1be95a0d5d18398252198d80f","unresolved":false,"context_lines":[{"line_number":677,"context_line":"        return self._caps"},{"line_number":678,"context_line":""},{"line_number":679,"context_line":"    def get_domain_capabilities(self):"},{"line_number":680,"context_line":"        \"\"\"Returns the host\u0027s domain capabilities information"},{"line_number":681,"context_line":""},{"line_number":682,"context_line":"        Returns an instance of config.LibvirtConfigDomainCaps"},{"line_number":683,"context_line":"        representing the domain capabilities of the host."}],"source_content_type":"text/x-python","patch_set":5,"id":"9fdfeff1_fbcae34c","line":680,"range":{"start_line":680,"start_character":23,"end_line":680,"end_character":49},"updated":"2019-02-26 14:16:53.000000000","message":"Suggest to rephrase it to:\n\n  \"Returns the host hypervisor\u0027s capabilities\"\n\nIf you\u0027d like to be extra clear, I\u0027d elaborate a bit more:\n\n  \"Returns the host hypervisor\u0027s capabilities \n\nIn this context the fuzzy word \"hypervisor\" implies QEMU binary, libvirt itself and the host config.\n\nAnd libvirt itself describes getDomainCapabilities() API as:\n\n    \"Prior creating a domain (for instance via virDomainCreateXML or\n    virDomainDefineXML) it may be suitable to know what the underlying\n    emulator and/or libvirt is capable of. For instance, if host, \n    libvirt and qemu is capable of VFIO passthrough and so on.\"","commit_id":"d9e9f25ce747ed15f82f3799d032ae9804a0b9fc"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"ef7eb31d2682aa92ee02e00738a1f630c6ae3a4d","unresolved":false,"context_lines":[{"line_number":690,"context_line":"        placement decisions can be made across many compute hosts."},{"line_number":691,"context_line":"        Therefore this is expected to be called during the init_host()"},{"line_number":692,"context_line":"        phase of the driver lifecycle rather than just before booting"},{"line_number":693,"context_line":"        an instance."},{"line_number":694,"context_line":""},{"line_number":695,"context_line":"        This causes an additional complication since the Python"},{"line_number":696,"context_line":"        binding for this libvirt API call requires the architecture"}],"source_content_type":"text/x-python","patch_set":7,"id":"9fdfeff1_46014104","line":693,"updated":"2019-03-05 14:54:18.000000000","message":"✔","commit_id":"02b018edd8317b7f8dc02a78a6f76ff963d511d2"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"ef7eb31d2682aa92ee02e00738a1f630c6ae3a4d","unresolved":false,"context_lines":[{"line_number":699,"context_line":"        with the right parameters."},{"line_number":700,"context_line":""},{"line_number":701,"context_line":"        Returns an instance of config.LibvirtConfigDomainCaps"},{"line_number":702,"context_line":"        representing the domain capabilities of the host."},{"line_number":703,"context_line":""},{"line_number":704,"context_line":"        Note: The result is cached in the member attribute"},{"line_number":705,"context_line":"        _domain_caps."}],"source_content_type":"text/x-python","patch_set":7,"id":"9fdfeff1_6619e578","line":702,"updated":"2019-03-05 14:54:18.000000000","message":"excellent docstring. thank you for putting effort into the things that the reader of this code will care about. ++","commit_id":"02b018edd8317b7f8dc02a78a6f76ff963d511d2"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"9766ab87347f3b97f3aa500c85a72f7b40dd31c7","unresolved":false,"context_lines":[{"line_number":699,"context_line":"        with the right parameters."},{"line_number":700,"context_line":""},{"line_number":701,"context_line":"        Returns an instance of config.LibvirtConfigDomainCaps"},{"line_number":702,"context_line":"        representing the domain capabilities of the host."},{"line_number":703,"context_line":""},{"line_number":704,"context_line":"        Note: The result is cached in the member attribute"},{"line_number":705,"context_line":"        _domain_caps."}],"source_content_type":"text/x-python","patch_set":7,"id":"5fc1f717_eec91678","line":702,"in_reply_to":"9fdfeff1_6619e578","updated":"2019-03-08 09:23:57.000000000","message":"Yes!  Thanks for reworking this significantly, Adam.","commit_id":"02b018edd8317b7f8dc02a78a6f76ff963d511d2"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"9766ab87347f3b97f3aa500c85a72f7b40dd31c7","unresolved":false,"context_lines":[{"line_number":737,"context_line":"                CONF.libvirt.virt_type,"},{"line_number":738,"context_line":"                flags"},{"line_number":739,"context_line":"            )"},{"line_number":740,"context_line":"            LOG.info(\"Libvirt host domain capabilities %s\", xmlstr)"},{"line_number":741,"context_line":"            self._domain_caps \u003d vconfig.LibvirtConfigDomainCaps()"},{"line_number":742,"context_line":"            self._domain_caps.parse_str(xmlstr)"},{"line_number":743,"context_line":"        return self._domain_caps"}],"source_content_type":"text/x-python","patch_set":7,"id":"5fc1f717_ee9ef661","line":740,"range":{"start_line":740,"start_character":30,"end_line":740,"end_character":41},"updated":"2019-03-08 09:23:57.000000000","message":"Please change this to: \"host hypervisor\" -- it also matches the change we did in the doc string :-).  (The term \"host domain\", although libvirt itself uses it some times, it is too Xen-specific.)\n\nIt\u0027s present on PS-10 as well.","commit_id":"02b018edd8317b7f8dc02a78a6f76ff963d511d2"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"ef7eb31d2682aa92ee02e00738a1f630c6ae3a4d","unresolved":false,"context_lines":[{"line_number":737,"context_line":"                CONF.libvirt.virt_type,"},{"line_number":738,"context_line":"                flags"},{"line_number":739,"context_line":"            )"},{"line_number":740,"context_line":"            LOG.info(\"Libvirt host domain capabilities %s\", xmlstr)"},{"line_number":741,"context_line":"            self._domain_caps \u003d vconfig.LibvirtConfigDomainCaps()"},{"line_number":742,"context_line":"            self._domain_caps.parse_str(xmlstr)"},{"line_number":743,"context_line":"        return self._domain_caps"}],"source_content_type":"text/x-python","patch_set":7,"id":"9fdfeff1_32179857","line":740,"updated":"2019-03-05 14:54:18.000000000","message":"✔","commit_id":"02b018edd8317b7f8dc02a78a6f76ff963d511d2"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"717a0eb80122f9d961dc9bfa4b7bf1d1ff41f9f1","unresolved":false,"context_lines":[{"line_number":737,"context_line":"                CONF.libvirt.virt_type,"},{"line_number":738,"context_line":"                flags"},{"line_number":739,"context_line":"            )"},{"line_number":740,"context_line":"            LOG.info(\"Libvirt host domain capabilities %s\", xmlstr)"},{"line_number":741,"context_line":"            self._domain_caps \u003d vconfig.LibvirtConfigDomainCaps()"},{"line_number":742,"context_line":"            self._domain_caps.parse_str(xmlstr)"},{"line_number":743,"context_line":"        return self._domain_caps"}],"source_content_type":"text/x-python","patch_set":7,"id":"5fc1f717_71e74be6","line":740,"range":{"start_line":740,"start_character":30,"end_line":740,"end_character":41},"in_reply_to":"5fc1f717_ee9ef661","updated":"2019-03-08 10:20:44.000000000","message":"Done as per http://eavesdrop.openstack.org/irclogs/%23openstack-nova/%23openstack-nova.2019-03-08.log.html#t2019-03-08T09:45:22","commit_id":"02b018edd8317b7f8dc02a78a6f76ff963d511d2"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"4ad8ff7749cd5f05116023cd3b9dbff1eefa0d56","unresolved":false,"context_lines":[{"line_number":708,"context_line":""},{"line_number":709,"context_line":"        \"\"\""},{"line_number":710,"context_line":"        if not self._domain_caps:"},{"line_number":711,"context_line":"            # TODO(aspiers): once https://review.openstack.org/#/c/640483/"},{"line_number":712,"context_line":"            # lands, we can determine these dynamically:"},{"line_number":713,"context_line":"            arch \u003d fields.Architecture.X86_64"},{"line_number":714,"context_line":"            emulatorbin \u003d \"/usr/bin/qemu-kvm\""}],"source_content_type":"text/x-python","patch_set":9,"id":"5fc1f717_a58592af","line":711,"range":{"start_line":711,"start_character":34,"end_line":711,"end_character":74},"updated":"2019-03-06 22:51:51.000000000","message":"this happened","commit_id":"7dcbace3f1754147f12d7c6ecf897e94b62aab13"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"5ef2cff77c79290f45d48fc86ce179fd1ccc6cfe","unresolved":false,"context_lines":[{"line_number":708,"context_line":""},{"line_number":709,"context_line":"        \"\"\""},{"line_number":710,"context_line":"        if not self._domain_caps:"},{"line_number":711,"context_line":"            # TODO(aspiers): once https://review.openstack.org/#/c/640483/"},{"line_number":712,"context_line":"            # lands, we can determine these dynamically:"},{"line_number":713,"context_line":"            arch \u003d fields.Architecture.X86_64"},{"line_number":714,"context_line":"            emulatorbin \u003d \"/usr/bin/qemu-kvm\""}],"source_content_type":"text/x-python","patch_set":9,"id":"5fc1f717_b2693f26","line":711,"range":{"start_line":711,"start_character":34,"end_line":711,"end_character":74},"in_reply_to":"5fc1f717_a58592af","updated":"2019-03-07 22:10:55.000000000","message":"Done","commit_id":"7dcbace3f1754147f12d7c6ecf897e94b62aab13"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"480e1298cf2d379333d698ab4386023736e0a1de","unresolved":false,"context_lines":[{"line_number":708,"context_line":""},{"line_number":709,"context_line":"        \"\"\""},{"line_number":710,"context_line":"        if not self._domain_caps:"},{"line_number":711,"context_line":"            # TODO(aspiers): once https://review.openstack.org/#/c/640483/"},{"line_number":712,"context_line":"            # lands, we can determine these dynamically:"},{"line_number":713,"context_line":"            arch \u003d fields.Architecture.X86_64"},{"line_number":714,"context_line":"            emulatorbin \u003d \"/usr/bin/qemu-kvm\""}],"source_content_type":"text/x-python","patch_set":9,"id":"5fc1f717_821cfe6a","line":711,"range":{"start_line":711,"start_character":34,"end_line":711,"end_character":74},"in_reply_to":"5fc1f717_a58592af","updated":"2019-03-07 12:21:57.000000000","message":"Yes, I\u0027ll be changing this shortly :-)","commit_id":"7dcbace3f1754147f12d7c6ecf897e94b62aab13"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"af3c170068561341cb4ae1c5f24a32853f7c79df","unresolved":false,"context_lines":[{"line_number":677,"context_line":"                        raise"},{"line_number":678,"context_line":"        return self._caps"},{"line_number":679,"context_line":""},{"line_number":680,"context_line":"    def get_domain_capabilities(self):"},{"line_number":681,"context_line":"        \"\"\"Returns the host hypervisor\u0027s capabilities information"},{"line_number":682,"context_line":"        for various combinations of architecture and machine type."},{"line_number":683,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"5fc1f717_18f9444c","line":680,"updated":"2019-03-08 15:42:53.000000000","message":"At the risk of adding more work ... would be really nice to split adding this method into its own patch, as it is not really tied to SEV, and also \"one logical change per patch\", and it\u0027s also useful for many other features.","commit_id":"55ae1740e33f8506f0a7f6e380538f2062aea2f4"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"674df0392370704a8443f57f8dc021b0b5fc5b69","unresolved":false,"context_lines":[{"line_number":677,"context_line":"                        raise"},{"line_number":678,"context_line":"        return self._caps"},{"line_number":679,"context_line":""},{"line_number":680,"context_line":"    def get_domain_capabilities(self):"},{"line_number":681,"context_line":"        \"\"\"Returns the host hypervisor\u0027s capabilities information"},{"line_number":682,"context_line":"        for various combinations of architecture and machine type."},{"line_number":683,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"5fc1f717_c5755534","line":680,"in_reply_to":"5fc1f717_18f9444c","updated":"2019-03-19 13:54:02.000000000","message":"Unfortunately I think it *is* somewhat tied to SEV, for two reasons as mentioned on IRC:\n\nhttp://eavesdrop.openstack.org/irclogs/%23openstack-nova/%23openstack-nova.2019-03-19.log.html#t2019-03-19T10:21:42\n\n1. The config parsing code added does *nothing* other than parse the \u003csev\u003e child element of \u003cfeatures\u003e.  If we split the parsing of \u003csev\u003e into a subsequent commit, there would be virtually nothing left to test with the parsing.  I could make it parse something else (e.g. \u003cpath\u003e or \u003cdomain\u003e or \u003carch\u003e) just for the sake of having something to test in the first patch, but that code path would not be exercised outside the tests.\n\n2. The design choice to only call the API once per architecture and memoize in a nested dict of dicts is a trade-off which comes directly from the fact that SEV support isn\u0027t (yet) reported per machine type.  The comment from line 706 below explains that by way of reference to an external SEV-specific bug.  So if we split the SEV stuff into a subsequent commit, either this comment stays in the preliminary getDomainCapabilities patch and prematurely references SEV before introducing support for it, or we move the comment into the SEV-specific patch in which case the preliminary one makes a significant design decision without properly explaining it.\n\nIf you can see a clean way to split it then please let me know, but right now I\u0027m not sure I can.","commit_id":"55ae1740e33f8506f0a7f6e380538f2062aea2f4"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"e26c824eddc728e127e38fa53816dd47bd8abcdd","unresolved":false,"context_lines":[{"line_number":677,"context_line":"                        raise"},{"line_number":678,"context_line":"        return self._caps"},{"line_number":679,"context_line":""},{"line_number":680,"context_line":"    def get_domain_capabilities(self):"},{"line_number":681,"context_line":"        \"\"\"Returns the host hypervisor\u0027s capabilities information"},{"line_number":682,"context_line":"        for various combinations of architecture and machine type."},{"line_number":683,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3fce034c_ed10faaa","line":680,"in_reply_to":"5fc1f717_c5755534","updated":"2019-04-18 11:15:46.000000000","message":"(Sorry for the delayed response.)\n\nI see the first point as a trade-off: the benefit of splitting getDomainCapabilities() outweighs the inconvenience of adding a couple of extra config object classes (we can leave a \"bread crumb trail of explanation\" in the commit messages outlining our rationale to help the reviewers and future readers of the code).\n\nI\u0027m coming from this point of view: Whenever Nova introduces a wrapper method around libvirt APIs, we should make it a separate commit without entangling it with any one higher-level feature.  Because there can be any number of other uses that are not related to it.  Case in point: I just learnt yesterday from the libvirt developers that the Secure Boot feature in Nova should check for the presence of a couple of XML elements in the output of the getDomainCapabilities().  (Yes, that\u0027s my \"vested interest\" here. :-))\n\nOn your second point, probably we can address it by the \"documentation judo\" you allude to?\n\nThanks for your patience.","commit_id":"55ae1740e33f8506f0a7f6e380538f2062aea2f4"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"5c95f1fab273c3513dbdd87d70d8ba940f2d6427","unresolved":false,"context_lines":[{"line_number":678,"context_line":"        return self._caps"},{"line_number":679,"context_line":""},{"line_number":680,"context_line":"    def get_domain_capabilities(self):"},{"line_number":681,"context_line":"        \"\"\"Returns the host hypervisor\u0027s capabilities information"},{"line_number":682,"context_line":"        for various combinations of architecture and machine type."},{"line_number":683,"context_line":""},{"line_number":684,"context_line":"        In this context the fuzzy word \"hypervisor\" implies QEMU"}],"source_content_type":"text/x-python","patch_set":11,"id":"5fc1f717_51541d53","line":681,"range":{"start_line":681,"start_character":11,"end_line":681,"end_character":65},"updated":"2019-03-14 15:40:49.000000000","message":"I know you changed the above to \"host hypervisor\u0027s capabilities\" on my request.  But after carefully reading libvirt\u0027s API docs and talking to another libvirt developer, I think it should be reworded as:\n\n  \"Returns the capabilities you can request when \n  creating a domain (VM) with that hypervisor\"\n\n\nI.e. we should distinguish between libvirt\u0027s getCapabilities(), which is also used by Nova, and getDomainCapabilities(). \n\nIn summary:\n\n- getCapabilities(): Tells you what libvirt knows about the host\u0027s capabilities (e.g. CPU features, NUMA capabilities, etc), and what QEMU emulator binaries are merely available on the said host; but it does *not* take into account what the given QEMU binary is _capable_ of.\n\n- getDomainCapabilities(): This answers the question: \"does the host allow XYZ feature _and_ the hypervisor (e.g. QEMU + KVM) allow exporting the feature through to guests\"?  So, if getDomainCapabilities() lists the feature you are interested in, then using that feature in \u003cdomain\u003e XML should work.\n\nIOW, it\u0027s not enough to know if libvirt knows about the feature, but also whether the specific QEMU binary chosen also supports the feature.\n\n\nI\u0027m also submitting a patch to libvirt to fix the awful terminology.","commit_id":"55ae1740e33f8506f0a7f6e380538f2062aea2f4"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"674df0392370704a8443f57f8dc021b0b5fc5b69","unresolved":false,"context_lines":[{"line_number":678,"context_line":"        return self._caps"},{"line_number":679,"context_line":""},{"line_number":680,"context_line":"    def get_domain_capabilities(self):"},{"line_number":681,"context_line":"        \"\"\"Returns the host hypervisor\u0027s capabilities information"},{"line_number":682,"context_line":"        for various combinations of architecture and machine type."},{"line_number":683,"context_line":""},{"line_number":684,"context_line":"        In this context the fuzzy word \"hypervisor\" implies QEMU"}],"source_content_type":"text/x-python","patch_set":11,"id":"5fc1f717_c5c31538","line":681,"range":{"start_line":681,"start_character":11,"end_line":681,"end_character":65},"in_reply_to":"5fc1f717_51541d53","updated":"2019-03-19 13:54:02.000000000","message":"Done","commit_id":"55ae1740e33f8506f0a7f6e380538f2062aea2f4"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"674df0392370704a8443f57f8dc021b0b5fc5b69","unresolved":false,"context_lines":[{"line_number":703,"context_line":"        the domain capabilities do not (yet, at least) vary enough"},{"line_number":704,"context_line":"        across machine types to justify the cost of calling"},{"line_number":705,"context_line":"        getDomainCapabilities() once for every single (architecture,"},{"line_number":706,"context_line":"        machine_type) combination.  In particular, SEV support isn\u0027t"},{"line_number":707,"context_line":"        reported per-machine type, and since there are usually many"},{"line_number":708,"context_line":"        machine types, we follow the advice of the experts that for"},{"line_number":709,"context_line":"        now it\u0027s sufficient to call it once per host architecture:"},{"line_number":710,"context_line":""},{"line_number":711,"context_line":"            https://bugzilla.redhat.com/show_bug.cgi?id\u003d1683471#c7"},{"line_number":712,"context_line":""},{"line_number":713,"context_line":"        However, future domain capabilities might report SEV more"},{"line_number":714,"context_line":"        fine-grained, and we also expect to use this to detect other"},{"line_number":715,"context_line":"        features, such as for gracefully handling machine types and"},{"line_number":716,"context_line":"        potentially for detecting OVMF binaries.  Therefore we memoize"},{"line_number":717,"context_line":"        the results of the API calls in a nested dict where the"}],"source_content_type":"text/x-python","patch_set":11,"id":"5fc1f717_85b66ddc","line":714,"range":{"start_line":706,"start_character":36,"end_line":714,"end_character":20},"updated":"2019-03-19 13:54:02.000000000","message":"As commented above, if we try to split this commit in two, where would this bit of the comment go?","commit_id":"55ae1740e33f8506f0a7f6e380538f2062aea2f4"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"674df0392370704a8443f57f8dc021b0b5fc5b69","unresolved":false,"context_lines":[{"line_number":712,"context_line":""},{"line_number":713,"context_line":"        However, future domain capabilities might report SEV more"},{"line_number":714,"context_line":"        fine-grained, and we also expect to use this to detect other"},{"line_number":715,"context_line":"        features, such as for gracefully handling machine types and"},{"line_number":716,"context_line":"        potentially for detecting OVMF binaries.  Therefore we memoize"},{"line_number":717,"context_line":"        the results of the API calls in a nested dict where the"},{"line_number":718,"context_line":"        top-level keys are architectures, and second-level keys are"},{"line_number":719,"context_line":"        machine types, in order to allow easy expansion later."}],"source_content_type":"text/x-python","patch_set":11,"id":"5fc1f717_05ca7d4e","line":716,"range":{"start_line":715,"start_character":18,"end_line":716,"end_character":48},"updated":"2019-03-19 13:54:02.000000000","message":"Although, partially countering my own argument, I\u0027m already making a dangling forward reference here ...  I guess forward-looking statements are not necessarily an issue.","commit_id":"55ae1740e33f8506f0a7f6e380538f2062aea2f4"}]}
