)]}'
{"nova/objects/image_meta.py":[{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"80a4dca78aa8db213463f6440ee4c04ff075c2d0","unresolved":false,"context_lines":[{"line_number":206,"context_line":"        # CPU mask indicates which vCPUs will have realtime enable,"},{"line_number":207,"context_line":"        # example ^0-1 means that all vCPUs except 0 and 1 will have a"},{"line_number":208,"context_line":"        # realtime policy."},{"line_number":209,"context_line":"        \u0027hw_cpu_realtime_mask\u0027: fields.StringField(),"},{"line_number":210,"context_line":""},{"line_number":211,"context_line":"        # preferred number of CPU threads per core"},{"line_number":212,"context_line":"        \u0027hw_cpu_threads\u0027: fields.IntegerField(),"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a8ffd7b_d0b5887e","line":209,"updated":"2015-11-24 16:33:16.000000000","message":"Reminds me that one day we should create a fields.CpuSpecField() field type that directly validates the data format using hardware.parse_cpu_spec().  Don\u0027t do that in this commit though - it is something we can cleanup later","commit_id":"f34c82de0b12e1494e77fe6e9ba6e19b37a98166"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"c701c06928677292b34dd30a201aeec384a1b912","unresolved":false,"context_lines":[{"line_number":41,"context_line":"    # Version 1.7: ImageMetaProps version 1.7"},{"line_number":42,"context_line":"    # Version 1.8: ImageMetaProps version 1.8"},{"line_number":43,"context_line":"    # Version 1.8: ImageMetaProps version 1.9"},{"line_number":44,"context_line":"    VERSION \u003d \u00271.9\u0027"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"    # These are driven by what the image client API returns"},{"line_number":47,"context_line":"    # to Nova from Glance. This is defined in the glance"}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_a932920e","line":44,"range":{"start_line":44,"start_character":15,"end_line":44,"end_character":18},"updated":"2016-01-04 15:33:31.000000000","message":"Same here - no need for the bump","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"}],"nova/objects/request_spec.py":[{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"c701c06928677292b34dd30a201aeec384a1b912","unresolved":false,"context_lines":[{"line_number":34,"context_line":"    # Version 1.4: ImageMeta version 1.7"},{"line_number":35,"context_line":"    # Version 1.5: Added get_by_instance_uuid(), create(), save()"},{"line_number":36,"context_line":"    # Version 1.6: ImageMeta version 1.8"},{"line_number":37,"context_line":"    VERSION \u003d \u00271.6\u0027"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"    fields \u003d {"},{"line_number":40,"context_line":"        \u0027id\u0027: fields.IntegerField(),"}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_497436ce","line":37,"range":{"start_line":37,"start_character":15,"end_line":37,"end_character":18},"updated":"2016-01-04 15:33:31.000000000","message":"I don\u0027t think we need to bump these anymore due to the manifest work Dan did.","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"}],"nova/tests/functional/libvirt/test_rt_servers.py":[{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"b7cf9723c01d70f29117cc5b16bd8b02ec07e444","unresolved":false,"context_lines":[{"line_number":131,"context_line":"            instance \u003d self.api.get_server(created[\u0027id\u0027])"},{"line_number":132,"context_line":"            instance \u003d self._wait_for_state_change(instance, \u0027BUILD\u0027)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"            self.assertEqual(\u0027ACTIVE\u0027, instance[\u0027status\u0027])"},{"line_number":135,"context_line":"            self._delete_server(instance[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a8ffd7b_f41ec96e","line":134,"updated":"2015-11-27 17:12:56.000000000","message":"Is there not a way you can check the extra specs have been applied inside the fake libvirt?","commit_id":"f34c82de0b12e1494e77fe6e9ba6e19b37a98166"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"31609448550d73d461599770d0941b107d1724cc","unresolved":false,"context_lines":[{"line_number":131,"context_line":"            instance \u003d self.api.get_server(created[\u0027id\u0027])"},{"line_number":132,"context_line":"            instance \u003d self._wait_for_state_change(instance, \u0027BUILD\u0027)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"            self.assertEqual(\u0027ACTIVE\u0027, instance[\u0027status\u0027])"},{"line_number":135,"context_line":"            self._delete_server(instance[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a8ffd7b_d21af56e","line":134,"in_reply_to":"9a8ffd7b_f41ec96e","updated":"2015-12-02 14:54:10.000000000","message":"Unfortunately I did not find way to verify this.","commit_id":"f34c82de0b12e1494e77fe6e9ba6e19b37a98166"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"27c25dcb2a41881addbf8a675d0575e63c979ad0","unresolved":false,"context_lines":[{"line_number":86,"context_line":"            self.api.post_server, {\u0027server\u0027: server})"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"    @mock.patch(\u0027nova.virt.libvirt.LibvirtDriver._create_image\u0027)"},{"line_number":89,"context_line":"    def test_invalid_libvirt_version(self, img_mock):"},{"line_number":90,"context_line":"        host_info \u003d NumaHostInfo(cpu_nodes\u003d2, cpu_sockets\u003d1, cpu_cores\u003d2,"},{"line_number":91,"context_line":"                                 cpu_threads\u003d2, kB_mem\u003d15740000)"},{"line_number":92,"context_line":"        fake_connection \u003d fakelibvirt.Connection(\u0027qemu:///system\u0027,"}],"source_content_type":"text/x-python","patch_set":30,"id":"fa69d971_1fb93415","line":89,"range":{"start_line":89,"start_character":8,"end_line":89,"end_character":36},"updated":"2016-01-06 10:04:58.000000000","message":"I really question the usefulness of this test as a functional test, when all the functionality we are testing is confined to the libvirt driver.\n\nTests come with a cost. \n\nThis is not related to this patch - just a general observation on the lemming-esque way we sometimes like to do things in Nova","commit_id":"6e9b856921a5a80bab6d1bad1bc25ef85dc5405f"}],"nova/virt/hardware.py":[{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"80a4dca78aa8db213463f6440ee4c04ff075c2d0","unresolved":false,"context_lines":[{"line_number":970,"context_line":"    mask \u003d image_mask or flavor_mask"},{"line_number":971,"context_line":"    if mask:"},{"line_number":972,"context_line":"        vcpus_spec \u003d format_cpu_spec(vcpus_set)"},{"line_number":973,"context_line":"        vcpus_rt \u003d parse_cpu_spec(vcpus_spec + \", \" + mask)"},{"line_number":974,"context_line":"        vcpus_em \u003d vcpus_set - vcpus_rt"},{"line_number":975,"context_line":""},{"line_number":976,"context_line":"        return vcpus_rt, vcpus_em"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a8ffd7b_dbc929ae","line":973,"updated":"2015-11-24 16:33:16.000000000","message":"Turning vcpus_set back into string format seems a bit wrong.\n\nIIUC, you are trying to take the intersection of mask \u0026 vcpus_set.  Can\u0027t we do this directly with set arithmetic by taking intersection of vcpus_set and mask\n\n   vcpus_rt \u003d vcpus_set \u0026 parse_cpu_spec(mask)","commit_id":"f34c82de0b12e1494e77fe6e9ba6e19b37a98166"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"9f4bafe204678c817bf9f9e4e6d124d18a308d84","unresolved":false,"context_lines":[{"line_number":970,"context_line":"    mask \u003d image_mask or flavor_mask"},{"line_number":971,"context_line":"    if mask:"},{"line_number":972,"context_line":"        vcpus_spec \u003d format_cpu_spec(vcpus_set)"},{"line_number":973,"context_line":"        vcpus_rt \u003d parse_cpu_spec(vcpus_spec + \", \" + mask)"},{"line_number":974,"context_line":"        vcpus_em \u003d vcpus_set - vcpus_rt"},{"line_number":975,"context_line":""},{"line_number":976,"context_line":"        return vcpus_rt, vcpus_em"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a8ffd7b_f96a87b2","line":973,"in_reply_to":"9a8ffd7b_dbc929ae","updated":"2015-11-26 11:17:49.000000000","message":"We cannot do something like that, a mask should be applied on a set of cpus, examples a mask like \u0027^1\u0027 will return an empty list which is not good. We actually want to exclude 1 from vcpus_set.","commit_id":"f34c82de0b12e1494e77fe6e9ba6e19b37a98166"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"b4db638f21c0dadc5649731a9c3b21fc0f0a68d2","unresolved":false,"context_lines":[{"line_number":970,"context_line":"    mask \u003d image_mask or flavor_mask"},{"line_number":971,"context_line":"    if mask:"},{"line_number":972,"context_line":"        vcpus_spec \u003d format_cpu_spec(vcpus_set)"},{"line_number":973,"context_line":"        vcpus_rt \u003d parse_cpu_spec(vcpus_spec + \", \" + mask)"},{"line_number":974,"context_line":"        vcpus_em \u003d vcpus_set - vcpus_rt"},{"line_number":975,"context_line":""},{"line_number":976,"context_line":"        return vcpus_rt, vcpus_em"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a8ffd7b_2e5190d8","line":973,"in_reply_to":"9a8ffd7b_f96a87b2","updated":"2015-11-26 16:51:01.000000000","message":"Oh hmm, yes, I see.","commit_id":"f34c82de0b12e1494e77fe6e9ba6e19b37a98166"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"c701c06928677292b34dd30a201aeec384a1b912","unresolved":false,"context_lines":[{"line_number":959,"context_line":""},{"line_number":960,"context_line":""},{"line_number":961,"context_line":"def is_realtime_enabled(flavor):"},{"line_number":962,"context_line":"    flavor_rt \u003d flavor.get(\u0027extra_specs\u0027, {}).get(\"hw:cpu_realtime\")"},{"line_number":963,"context_line":"    return strutils.bool_from_string(flavor_rt)"},{"line_number":964,"context_line":""},{"line_number":965,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_bad73222","line":962,"range":{"start_line":962,"start_character":51,"end_line":962,"end_character":66},"updated":"2016-01-04 15:33:31.000000000","message":"This is somewhat related to this patch. According to the BP having all cpus specified as RT is an error, however I don\u0027t see that codified anywhere.\n\nIt should be in this method preferably since it should error out in the API.","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"a4ff2b4daf43b7b8f541d1fde18c68ef494fb072","unresolved":false,"context_lines":[{"line_number":959,"context_line":""},{"line_number":960,"context_line":""},{"line_number":961,"context_line":"def is_realtime_enabled(flavor):"},{"line_number":962,"context_line":"    flavor_rt \u003d flavor.get(\u0027extra_specs\u0027, {}).get(\"hw:cpu_realtime\")"},{"line_number":963,"context_line":"    return strutils.bool_from_string(flavor_rt)"},{"line_number":964,"context_line":""},{"line_number":965,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_9d2ec141","line":962,"in_reply_to":"fa69d971_9c7b27f5","updated":"2016-01-05 10:53:05.000000000","message":"With other stuff in this module the pattern was that we have a method we call in the API service to verify that the flavor/image are configured properly and fail otherwise.\n\nI think this is a slightly better pattern than failing on the compute node. Regardless of where we do it - we should make sure we are not allowing all CPUs to be dedicated to RT, which we are not checking anywhere atm.","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"8a8a0fcd7c7a1bdad167b71a5149eb16f8689e12","unresolved":false,"context_lines":[{"line_number":959,"context_line":""},{"line_number":960,"context_line":""},{"line_number":961,"context_line":"def is_realtime_enabled(flavor):"},{"line_number":962,"context_line":"    flavor_rt \u003d flavor.get(\u0027extra_specs\u0027, {}).get(\"hw:cpu_realtime\")"},{"line_number":963,"context_line":"    return strutils.bool_from_string(flavor_rt)"},{"line_number":964,"context_line":""},{"line_number":965,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_9c7b27f5","line":962,"in_reply_to":"fa69d971_bad73222","updated":"2016-01-05 09:40:14.000000000","message":"This method is just indicating whether realtime is enable or not. This method does not indicate whether flavor is well configured, for example cpu_policy should to be configured as dedicated too.","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"c701c06928677292b34dd30a201aeec384a1b912","unresolved":false,"context_lines":[{"line_number":963,"context_line":"    return strutils.bool_from_string(flavor_rt)"},{"line_number":964,"context_line":""},{"line_number":965,"context_line":""},{"line_number":966,"context_line":"def vcpus_realtime_topology(vcpus_set, flavor, image):"},{"line_number":967,"context_line":"    flavor_mask \u003d flavor.get(\u0027extra_specs\u0027, {}).get(\"hw:cpu_realtime_mask\")"},{"line_number":968,"context_line":"    image_mask \u003d image.properties.get(\"hw_cpu_realtime_mask\")"},{"line_number":969,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_a49637ee","line":966,"range":{"start_line":966,"start_character":4,"end_line":966,"end_character":27},"updated":"2016-01-04 15:33:31.000000000","message":"This particular method could definitely use some more documentation. I have literally no idea what this is supposed to do since it just manipulates sets","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"8a8a0fcd7c7a1bdad167b71a5149eb16f8689e12","unresolved":false,"context_lines":[{"line_number":963,"context_line":"    return strutils.bool_from_string(flavor_rt)"},{"line_number":964,"context_line":""},{"line_number":965,"context_line":""},{"line_number":966,"context_line":"def vcpus_realtime_topology(vcpus_set, flavor, image):"},{"line_number":967,"context_line":"    flavor_mask \u003d flavor.get(\u0027extra_specs\u0027, {}).get(\"hw:cpu_realtime_mask\")"},{"line_number":968,"context_line":"    image_mask \u003d image.properties.get(\"hw_cpu_realtime_mask\")"},{"line_number":969,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_bc806bc1","line":966,"in_reply_to":"fa69d971_a49637ee","updated":"2016-01-05 09:40:14.000000000","message":"Done","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"c701c06928677292b34dd30a201aeec384a1b912","unresolved":false,"context_lines":[{"line_number":967,"context_line":"    flavor_mask \u003d flavor.get(\u0027extra_specs\u0027, {}).get(\"hw:cpu_realtime_mask\")"},{"line_number":968,"context_line":"    image_mask \u003d image.properties.get(\"hw_cpu_realtime_mask\")"},{"line_number":969,"context_line":""},{"line_number":970,"context_line":"    mask \u003d image_mask or flavor_mask"},{"line_number":971,"context_line":"    if mask:"},{"line_number":972,"context_line":"        vcpus_spec \u003d format_cpu_spec(vcpus_set)"},{"line_number":973,"context_line":"        vcpus_rt \u003d parse_cpu_spec(vcpus_spec + \", \" + mask)"}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_df30d803","line":970,"range":{"start_line":970,"start_character":11,"end_line":970,"end_character":36},"updated":"2016-01-04 15:33:31.000000000","message":"I guess it\u0027s OK for the image to be able to override the CPU mask...","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"a4ff2b4daf43b7b8f541d1fde18c68ef494fb072","unresolved":false,"context_lines":[{"line_number":967,"context_line":"    flavor_mask \u003d flavor.get(\u0027extra_specs\u0027, {}).get(\"hw:cpu_realtime_mask\")"},{"line_number":968,"context_line":"    image_mask \u003d image.properties.get(\"hw_cpu_realtime_mask\")"},{"line_number":969,"context_line":""},{"line_number":970,"context_line":"    mask \u003d image_mask or flavor_mask"},{"line_number":971,"context_line":"    if mask:"},{"line_number":972,"context_line":"        vcpus_spec \u003d format_cpu_spec(vcpus_set)"},{"line_number":973,"context_line":"        vcpus_rt \u003d parse_cpu_spec(vcpus_spec + \", \" + mask)"}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_7d298d36","line":970,"in_reply_to":"fa69d971_bca86b8e","updated":"2016-01-05 10:53:05.000000000","message":"No - this is fine!","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"8a8a0fcd7c7a1bdad167b71a5149eb16f8689e12","unresolved":false,"context_lines":[{"line_number":967,"context_line":"    flavor_mask \u003d flavor.get(\u0027extra_specs\u0027, {}).get(\"hw:cpu_realtime_mask\")"},{"line_number":968,"context_line":"    image_mask \u003d image.properties.get(\"hw_cpu_realtime_mask\")"},{"line_number":969,"context_line":""},{"line_number":970,"context_line":"    mask \u003d image_mask or flavor_mask"},{"line_number":971,"context_line":"    if mask:"},{"line_number":972,"context_line":"        vcpus_spec \u003d format_cpu_spec(vcpus_set)"},{"line_number":973,"context_line":"        vcpus_rt \u003d parse_cpu_spec(vcpus_spec + \", \" + mask)"}],"source_content_type":"text/x-python","patch_set":28,"id":"fa69d971_bca86b8e","line":970,"in_reply_to":"fa69d971_df30d803","updated":"2016-01-05 09:40:14.000000000","message":"If operator allow to use realtime for a flavor i do not see problem to have image able to override mask, is there one ?","commit_id":"e9a215799e4a9fe24b3e060a536f7a61b2a3ec43"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"b0f0751480f6721f9b75519af51da0ebab259931","unresolved":false,"context_lines":[{"line_number":975,"context_line":""},{"line_number":976,"context_line":"    mask \u003d image_mask or flavor_mask"},{"line_number":977,"context_line":"    if not mask:"},{"line_number":978,"context_line":"        raise exception.RealtimeMaskNotFoundOrInvalid()"},{"line_number":979,"context_line":""},{"line_number":980,"context_line":"    vcpus_spec \u003d format_cpu_spec(vcpus_set)"},{"line_number":981,"context_line":"    vcpus_rt \u003d parse_cpu_spec(vcpus_spec + \", \" + mask)"}],"source_content_type":"text/x-python","patch_set":29,"id":"fa69d971_9df00169","line":978,"range":{"start_line":978,"start_character":9,"end_line":978,"end_character":53},"updated":"2016-01-05 11:39:21.000000000","message":"It would be preferable (IMHO) to do this check in the API, however we can do that as a follow on if we agree that it\u0027s useful.","commit_id":"5712ae1cba406e6ee59131a1c6d4b69612005bf5"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"27c25dcb2a41881addbf8a675d0575e63c979ad0","unresolved":false,"context_lines":[{"line_number":995,"context_line":""},{"line_number":996,"context_line":"    mask \u003d image_mask or flavor_mask"},{"line_number":997,"context_line":"    if not mask:"},{"line_number":998,"context_line":"        raise exception.RealtimeMaskNotFoundOrInvalid()"},{"line_number":999,"context_line":""},{"line_number":1000,"context_line":"    vcpus_spec \u003d format_cpu_spec(vcpus_set)"},{"line_number":1001,"context_line":"    vcpus_rt \u003d parse_cpu_spec(vcpus_spec + \", \" + mask)"}],"source_content_type":"text/x-python","patch_set":30,"id":"fa69d971_1f15b4e3","line":998,"range":{"start_line":998,"start_character":15,"end_line":998,"end_character":53},"updated":"2016-01-06 10:04:58.000000000","message":"Still think that this check should run in the API - we have all the info - we can do it later though.","commit_id":"6e9b856921a5a80bab6d1bad1bc25ef85dc5405f"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"33083085a9504c34e02da642613488c9364b6a76","unresolved":false,"context_lines":[{"line_number":995,"context_line":""},{"line_number":996,"context_line":"    mask \u003d image_mask or flavor_mask"},{"line_number":997,"context_line":"    if not mask:"},{"line_number":998,"context_line":"        raise exception.RealtimeMaskNotFoundOrInvalid()"},{"line_number":999,"context_line":""},{"line_number":1000,"context_line":"    vcpus_spec \u003d format_cpu_spec(vcpus_set)"},{"line_number":1001,"context_line":"    vcpus_rt \u003d parse_cpu_spec(vcpus_spec + \", \" + mask)"}],"source_content_type":"text/x-python","patch_set":30,"id":"fa69d971_731bc481","line":998,"in_reply_to":"fa69d971_1f15b4e3","updated":"2016-01-06 13:05:49.000000000","message":"Let me to provide a commit to do that check in API layer","commit_id":"6e9b856921a5a80bab6d1bad1bc25ef85dc5405f"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"8604188d0248b3c2872ebe4749092d15b885d9b6","unresolved":false,"context_lines":[{"line_number":3881,"context_line":""},{"line_number":3882,"context_line":"        return membacking"},{"line_number":3883,"context_line":""},{"line_number":3884,"context_line":"    def _set_memory_backing_realtime_support("},{"line_number":3885,"context_line":"            self, membacking, flavor, image_meta):"},{"line_number":3886,"context_line":"        if not membacking:"},{"line_number":3887,"context_line":"            membacking \u003d vconfig.LibvirtConfigGuestMemoryBacking()"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba3cc151_ceb0648e","line":3884,"updated":"2015-07-07 05:24:41.000000000","message":"We need to verify if the version of libvirt used provide support of scheduler policy (1.2.13)","commit_id":"2fc1291cfaaa47dd3dd5d7c1d915e3e5fa51446d"},{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"5a1e57e39680ee7b5ef9b48e6c985b4d5ded12d2","unresolved":false,"context_lines":[{"line_number":3868,"context_line":""},{"line_number":3869,"context_line":"    def _get_guest_memory_backing_config("},{"line_number":3870,"context_line":"            self, inst_topology, numatune, flavor, image_meta):"},{"line_number":3871,"context_line":"        wantsmempages, wantsrealtime \u003d False, False"},{"line_number":3872,"context_line":"        if inst_topology:"},{"line_number":3873,"context_line":"            for cell in inst_topology.cells:"},{"line_number":3874,"context_line":"                if cell.pagesize:"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba3cc151_e1d11dcd","line":3871,"updated":"2015-07-09 15:51:51.000000000","message":"we don\u0027t need init here, line 3878 always set it","commit_id":"33035cfb5f75223b35fbbf3d92586cf255fe351f"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"9181032d9343dfb55fb3fa5505fe2c7df243eb14","unresolved":false,"context_lines":[{"line_number":3868,"context_line":""},{"line_number":3869,"context_line":"    def _get_guest_memory_backing_config("},{"line_number":3870,"context_line":"            self, inst_topology, numatune, flavor, image_meta):"},{"line_number":3871,"context_line":"        wantsmempages, wantsrealtime \u003d False, False"},{"line_number":3872,"context_line":"        if inst_topology:"},{"line_number":3873,"context_line":"            for cell in inst_topology.cells:"},{"line_number":3874,"context_line":"                if cell.pagesize:"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a41bdd9_d555e1c1","line":3871,"in_reply_to":"ba3cc151_e1d11dcd","updated":"2015-07-15 12:50:15.000000000","message":"Done","commit_id":"33035cfb5f75223b35fbbf3d92586cf255fe351f"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"7a3661745e944134bd43e96d8d37a5be1d688b98","unresolved":false,"context_lines":[{"line_number":3598,"context_line":"                            MIN_LIBVIRT_REALTIME_VERSION):"},{"line_number":3599,"context_line":"                        raise exception.RealtimePolicyNotSupported()"},{"line_number":3600,"context_line":"                    vcpusched \u003d vconfig.LibvirtConfigGuestCPUTuneVCPUSched()"},{"line_number":3601,"context_line":"                    guest_cpu_tune.vcpusched \u003d vcpusched"},{"line_number":3602,"context_line":""},{"line_number":3603,"context_line":"                guest_numa_tune.memory \u003d numa_mem"},{"line_number":3604,"context_line":"                guest_numa_tune.memnodes \u003d numa_memnodes"}],"source_content_type":"text/x-python","patch_set":5,"id":"3a50d1a3_e7d4d7ec","line":3601,"updated":"2015-07-23 10:16:40.000000000","message":"The is an error in libvirt\u0027s docs, attribute vcpus needs to be declared for element vcpusched","commit_id":"e2a3acab8ddf237af32781d37fb8a9be527b6884"},{"author":{"_account_id":17863,"name":"henning.schild","email":"henning.schild@siemens.com","username":"henning.schild"},"change_message_id":"e14f04ce94b0bab9bae6bc5ca0596dc7cb8280fb","unresolved":false,"context_lines":[{"line_number":3588,"context_line":"                # cross NUMA node traffic. This is an area of investigation"},{"line_number":3589,"context_line":"                # for QEMU community devs."},{"line_number":3590,"context_line":"                emulatorpin \u003d vconfig.LibvirtConfigGuestCPUTuneEmulatorPin()"},{"line_number":3591,"context_line":"                emulatorpin.cpuset \u003d set(allpcpus)"},{"line_number":3592,"context_line":"                guest_cpu_tune.emulatorpin \u003d emulatorpin"},{"line_number":3593,"context_line":"                # Sort the vcpupin list per vCPU id for human-friendlier XML"},{"line_number":3594,"context_line":"                guest_cpu_tune.vcpupin.sort(key\u003doperator.attrgetter(\"id\"))"}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_869734eb","line":3591,"updated":"2015-08-12 15:26:36.000000000","message":"doing that in the realtime case will mean that the PCPUs will have to handle more than just the VCPU threads\nIt will spread io threads over the realtime pcpus","commit_id":"59d1e190ee2e91bf608e8d2ee0487f16c7233bba"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"c2dae77f319f7b46b302e76767a774b58dc6a619","unresolved":false,"context_lines":[{"line_number":3588,"context_line":"                # cross NUMA node traffic. This is an area of investigation"},{"line_number":3589,"context_line":"                # for QEMU community devs."},{"line_number":3590,"context_line":"                emulatorpin \u003d vconfig.LibvirtConfigGuestCPUTuneEmulatorPin()"},{"line_number":3591,"context_line":"                emulatorpin.cpuset \u003d set(allpcpus)"},{"line_number":3592,"context_line":"                guest_cpu_tune.emulatorpin \u003d emulatorpin"},{"line_number":3593,"context_line":"                # Sort the vcpupin list per vCPU id for human-friendlier XML"},{"line_number":3594,"context_line":"                guest_cpu_tune.vcpupin.sort(key\u003doperator.attrgetter(\"id\"))"}],"source_content_type":"text/x-python","patch_set":6,"id":"fa1b9901_eb0bd97b","line":3591,"in_reply_to":"1a4dcd0f_869734eb","updated":"2015-08-24 13:10:19.000000000","message":"Yes this seems to be exact, we should to isolate this at some point.\n\nWe have \u0027vcpu_pin_set\u0027 to define which pcpus instances can use. We can probably have option \u0027emulator_pin_set\u0027 to define on which pcpus emulators can run.","commit_id":"59d1e190ee2e91bf608e8d2ee0487f16c7233bba"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"9ca4c18f75563ced26b258d9609d589c7d5797f6","unresolved":false,"context_lines":[{"line_number":3588,"context_line":"                # cross NUMA node traffic. This is an area of investigation"},{"line_number":3589,"context_line":"                # for QEMU community devs."},{"line_number":3590,"context_line":"                emulatorpin \u003d vconfig.LibvirtConfigGuestCPUTuneEmulatorPin()"},{"line_number":3591,"context_line":"                emulatorpin.cpuset \u003d set(allpcpus)"},{"line_number":3592,"context_line":"                guest_cpu_tune.emulatorpin \u003d emulatorpin"},{"line_number":3593,"context_line":"                # Sort the vcpupin list per vCPU id for human-friendlier XML"},{"line_number":3594,"context_line":"                guest_cpu_tune.vcpupin.sort(key\u003doperator.attrgetter(\"id\"))"}],"source_content_type":"text/x-python","patch_set":6,"id":"fa1b9901_d86aed80","line":3591,"in_reply_to":"fa1b9901_8c811092","updated":"2015-08-26 15:13:35.000000000","message":"So currently we do not provide a way to partition I/O threads. That means vCPUs and I/O threads will run a same pCPUs allowed for RT.\n\nAbout your solution to have a set of host pCPUs dedicated for RT (pcpu_set_rt), I do not see how that solves problem you have also mentioned about to have for instance a VM with 1 vCPU dedicated for RT and an other for \"best-effort\" OR perhaps I misunderstood something ?\n\nAn other solution would be to use option hw:cpu_realtime differently and instead of setting true/false make it handle number of pCPUs reserved for RT.\n\nIt means that we have possibility to partition emulator and RT-vCPUs. For a flavor asking same number of vCPUs than hw:cpu_realtime is requesting so emulator and RT-vCPUs while share same pCPUs. If hw:cpu_realtime is less so emulator will be pinned to the difference of number vCPUs allowed from flavor with number of reserved for RT.\n\nIn a second time we could define a real topology:\n\n  hw:cpu_realtime.0 \u003d cpu\n  hw:cpu_realtime.1 \u003d cpu\n  hw:cpu_realtime.2 \u003d iothread\n  hw:cpu_realtime.3 \u003d emulator\n\nOR\n\n  hw:cpu_realtime.0 \u003d cpu, iothread\n  hw:cpu_realtime.1 \u003d emulaor\n  \nAnd that could be implemented on top of numa to take part of nodes placement:\n\n  hw:numa_nodes \u003d 2\n  hw:numa_node.0 \u003d 0, 1, 2\n  hw:numa_node.1 \u003d 3","commit_id":"59d1e190ee2e91bf608e8d2ee0487f16c7233bba"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"b2c890b4ebd34709f1c9974f4dc4318b257d54db","unresolved":false,"context_lines":[{"line_number":3588,"context_line":"                # cross NUMA node traffic. This is an area of investigation"},{"line_number":3589,"context_line":"                # for QEMU community devs."},{"line_number":3590,"context_line":"                emulatorpin \u003d vconfig.LibvirtConfigGuestCPUTuneEmulatorPin()"},{"line_number":3591,"context_line":"                emulatorpin.cpuset \u003d set(allpcpus)"},{"line_number":3592,"context_line":"                guest_cpu_tune.emulatorpin \u003d emulatorpin"},{"line_number":3593,"context_line":"                # Sort the vcpupin list per vCPU id for human-friendlier XML"},{"line_number":3594,"context_line":"                guest_cpu_tune.vcpupin.sort(key\u003doperator.attrgetter(\"id\"))"}],"source_content_type":"text/x-python","patch_set":6,"id":"da20952f_0175e9c9","line":3591,"in_reply_to":"fa1b9901_d86aed80","updated":"2015-08-27 09:36:33.000000000","message":"Currently Nova does not make use of explicit I/O threads at all, so we don\u0027t really need to consider them right now. We really just have the vCPU threads and the emulator threads (which includes zero or more implicit I/O threads).\n\nWhen doing real-time we clearly must have the emulator thread(s) separate from vCPU threads. Thi essentially means that the schedular filter must reserve N+1 host CPUs for a flavour with N vCPUs, with the extra pCPU being used for the emulator threads. Even in non-realtime cases, we probably want to have the option to specify dedicated emulator thread CPU as an alternative to spreading. So re-using the hw:cpu_realtime property is not appropriate IMHO.\n\nSo I suggest we need a new image property\n\n  hw_cpu_emulator \u003d spread|dedicated\n\nwhich controls where the emulator threads live\n\nAlternatively we could add a third option to the existing hw_cpu_mode \u003d shared|dedicated but that feels a little dirty\n\n\nNB, this is probably something that should be described \u0026 discussed in the spec, rather than the code review.","commit_id":"59d1e190ee2e91bf608e8d2ee0487f16c7233bba"},{"author":{"_account_id":17863,"name":"henning.schild","email":"henning.schild@siemens.com","username":"henning.schild"},"change_message_id":"2e38ec36c1fe9fcda901792315111441f5ee1ecf","unresolved":false,"context_lines":[{"line_number":3588,"context_line":"                # cross NUMA node traffic. This is an area of investigation"},{"line_number":3589,"context_line":"                # for QEMU community devs."},{"line_number":3590,"context_line":"                emulatorpin \u003d vconfig.LibvirtConfigGuestCPUTuneEmulatorPin()"},{"line_number":3591,"context_line":"                emulatorpin.cpuset \u003d set(allpcpus)"},{"line_number":3592,"context_line":"                guest_cpu_tune.emulatorpin \u003d emulatorpin"},{"line_number":3593,"context_line":"                # Sort the vcpupin list per vCPU id for human-friendlier XML"},{"line_number":3594,"context_line":"                guest_cpu_tune.vcpupin.sort(key\u003doperator.attrgetter(\"id\"))"}],"source_content_type":"text/x-python","patch_set":6,"id":"fa1b9901_8c811092","line":3591,"in_reply_to":"fa1b9901_eb0bd97b","updated":"2015-08-24 14:59:02.000000000","message":"Actually \u0027vcpu_pin_set\u0027 should be renamed because it is totally confusing and does not reflect what it does. (maybe \u0027pcpu_set\u0027)\nFor realtime we should add \u0027pcpu_set_rt\u0027.\nIf a VM has realtime CPUs they should be taken from the _rt set, and exclusive. When we get additional requirements, like rt IO we could also choose to pin certain IO threads to a dedicated rt-CPU.\nWe can have VMs where only some vcpus will be RT. In a smp guest one core will probably be best-effort anyways why burn a host rt-CPU for that vcpu?\nAnd we get mixed RT-/best-effort compute nodes \"for free\", because for RT we essentially need to implement mixed mode.\n\nAt the moment we actually added something like your proposed \u0027emulator_pin_set\u0027 to our prototype, just because it is the shortest way to get something working.","commit_id":"59d1e190ee2e91bf608e8d2ee0487f16c7233bba"},{"author":{"_account_id":17021,"name":"Adriaan Schmidt","email":"adriaan.schmidt@siemens.com","username":"adriaan42"},"change_message_id":"7c7bfb8deda9503020ca6c59e7f9c10b3699b8da","unresolved":false,"context_lines":[{"line_number":3596,"context_line":"                if hardware.is_realtime_enabled(flavor, image_meta):"},{"line_number":3597,"context_line":"                    if not self._host.has_min_version("},{"line_number":3598,"context_line":"                            MIN_LIBVIRT_REALTIME_VERSION):"},{"line_number":3599,"context_line":"                        raise exception.RealtimePolicyNotSupported()"},{"line_number":3600,"context_line":"                    vcpusched \u003d vconfig.LibvirtConfigGuestCPUTuneVCPUSched()"},{"line_number":3601,"context_line":"                    vcpusched.vcpus \u003d [cpu.id for cpu in guest_cpu_tune.vcpupin]"},{"line_number":3602,"context_line":"                    guest_cpu_tune.vcpusched \u003d vcpusched"}],"source_content_type":"text/x-python","patch_set":6,"id":"3a50d1a3_07fd8eb0","line":3599,"updated":"2015-08-04 13:03:54.000000000","message":"Will nova-compute detect if its host is realtime-capable? Currently, there is only this check for the Libvirt version, but there are a lot more factors (e.g. realtime-capable host kernel). \nIf we do not auto-detect realtime-capabilities, should there be a config file option to set it, so a non-RT host would not accept RT instances?","commit_id":"59d1e190ee2e91bf608e8d2ee0487f16c7233bba"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"c2dae77f319f7b46b302e76767a774b58dc6a619","unresolved":false,"context_lines":[{"line_number":3596,"context_line":"                if hardware.is_realtime_enabled(flavor, image_meta):"},{"line_number":3597,"context_line":"                    if not self._host.has_min_version("},{"line_number":3598,"context_line":"                            MIN_LIBVIRT_REALTIME_VERSION):"},{"line_number":3599,"context_line":"                        raise exception.RealtimePolicyNotSupported()"},{"line_number":3600,"context_line":"                    vcpusched \u003d vconfig.LibvirtConfigGuestCPUTuneVCPUSched()"},{"line_number":3601,"context_line":"                    vcpusched.vcpus \u003d [cpu.id for cpu in guest_cpu_tune.vcpupin]"},{"line_number":3602,"context_line":"                    guest_cpu_tune.vcpusched \u003d vcpusched"}],"source_content_type":"text/x-python","patch_set":6,"id":"fa1b9901_4b63e541","line":3599,"in_reply_to":"3a50d1a3_07fd8eb0","updated":"2015-08-24 13:10:19.000000000","message":"We expect that, operators will use aggregates to isolate hosts running in realtime. So there is no need of a special option.","commit_id":"59d1e190ee2e91bf608e8d2ee0487f16c7233bba"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"9a2eba51bb48313aaa251b366fdc8ab54727a11d","unresolved":false,"context_lines":[{"line_number":3599,"context_line":"                        raise exception.RealtimePolicyNotSupported()"},{"line_number":3600,"context_line":"                    vcpusched \u003d vconfig.LibvirtConfigGuestCPUTuneVCPUSched()"},{"line_number":3601,"context_line":"                    vcpusched.vcpus \u003d [cpu.id for cpu in guest_cpu_tune.vcpupin]"},{"line_number":3602,"context_line":"                    guest_cpu_tune.vcpusched \u003d vcpusched"},{"line_number":3603,"context_line":""},{"line_number":3604,"context_line":"                guest_numa_tune.memory \u003d numa_mem"},{"line_number":3605,"context_line":"                guest_numa_tune.memnodes \u003d numa_memnodes"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_47bf46aa","line":3602,"updated":"2015-09-22 10:02:49.000000000","message":"We need to set the schedular policy and priority attributes against the vcpusched object, since the defaults are not suitable.\n\nPer my latest version of the spec, we should also honour the hw:cpu_realtime_mask flavour extra spec / image meta property, which says which of the vCPUs are to have real-time enabled. We\u0027ll also need look at this property to decide which CPUs to pin the emulator threads to.","commit_id":"59d1e190ee2e91bf608e8d2ee0487f16c7233bba"},{"author":{"_account_id":17863,"name":"henning.schild","email":"henning.schild@siemens.com","username":"henning.schild"},"change_message_id":"73a44b6d3879625f217f932524b774cf31c89520","unresolved":false,"context_lines":[{"line_number":3982,"context_line":"        if not membacking:"},{"line_number":3983,"context_line":"            membacking \u003d vconfig.LibvirtConfigGuestMemoryBacking()"},{"line_number":3984,"context_line":"        membacking.locked \u003d True"},{"line_number":3985,"context_line":"        membacking.sharedpages \u003d False"},{"line_number":3986,"context_line":""},{"line_number":3987,"context_line":"        return membacking"},{"line_number":3988,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_845accf0","line":3985,"updated":"2015-09-30 09:25:46.000000000","message":"We are using vhost-user in combination with rt-VMs. For that to work we need hugepages that are shared. Why do force shared to False?","commit_id":"c68e6e9a5f03b27c958d1cdb108a076ebf2c373d"},{"author":{"_account_id":14358,"name":"Marian Horban","email":"m.horban@gmail.com","username":"mhorban"},"change_message_id":"c38154aac3f6c96875fb283e762b0d027b2f96dd","unresolved":false,"context_lines":[{"line_number":274,"context_line":"    cfg.IntOpt(\u0027realtime_scheduler_priority\u0027,"},{"line_number":275,"context_line":"               default\u003d1,"},{"line_number":276,"context_line":"               help\u003d\u0027In a realtime host context vCPUs for guest will run in \u0027"},{"line_number":277,"context_line":"               \u0027that scheduling priority. Priority depends on the host \u0027"},{"line_number":278,"context_line":"               \u0027kernel (usually 1-99)\u0027)"},{"line_number":279,"context_line":"    ]"},{"line_number":280,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"fa80f949_98565d05","line":277,"updated":"2015-11-03 10:37:30.000000000","message":"indentation","commit_id":"c4076751a7549b254a2296607bacaefad56d72ec"},{"author":{"_account_id":14358,"name":"Marian Horban","email":"m.horban@gmail.com","username":"mhorban"},"change_message_id":"c38154aac3f6c96875fb283e762b0d027b2f96dd","unresolved":false,"context_lines":[{"line_number":4026,"context_line":"                    wantsmempages \u003d True"},{"line_number":4027,"context_line":"                    break"},{"line_number":4028,"context_line":""},{"line_number":4029,"context_line":"        wantsrealtime \u003d hardware.is_realtime_enabled(flavor)"},{"line_number":4030,"context_line":""},{"line_number":4031,"context_line":"        membacking \u003d None"},{"line_number":4032,"context_line":"        if wantsmempages:"}],"source_content_type":"text/x-python","patch_set":13,"id":"fa80f949_f8d44948","line":4029,"updated":"2015-11-03 10:37:30.000000000","message":"Name of variable should use underscore style:  wants_real_time","commit_id":"c4076751a7549b254a2296607bacaefad56d72ec"}]}
