)]}'
{"doc/source/user/placement.rst":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"de736fec4e280bad6c09a99bfb58689121aa1a09","unresolved":false,"context_lines":[{"line_number":294,"context_line":"Rocky (18.0.0)"},{"line_number":295,"context_line":"~~~~~~~~~~~~~~"},{"line_number":296,"context_line":""},{"line_number":297,"context_line":"* The minimum Placement API microversion required by the *nova-scheduler*"},{"line_number":298,"context_line":"  service is ``1.26`` in order to `allow reserving all the resource provider\u0027s"},{"line_number":299,"context_line":"  resources`_."},{"line_number":300,"context_line":"  This means you must upgrade the placement service before upgrading any"}],"source_content_type":"text/x-rst","patch_set":15,"id":"5f7c97a3_2995de94","line":297,"range":{"start_line":297,"start_character":57,"end_line":297,"end_character":73},"updated":"2018-07-24 18:41:23.000000000","message":"Not really true, this would be nova-compute now; I\u0027m not really sure if we should change anything here. At some point we\u0027ll probably just stop adding this kind of release note since we assert you should upgrade placement before any nova services.","commit_id":"eeca3bc4574a0375bf25269993eb012a8c4d51b3"}],"nova/cmd/status.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4e4a05f9ac975c9216774b9bdf424ed0863d5b4b","unresolved":false,"context_lines":[{"line_number":52,"context_line":"PLACEMENT_DOCS_LINK \u003d \u0027https://docs.openstack.org/nova/latest\u0027 \\"},{"line_number":53,"context_line":"                      \u0027/user/placement.html\u0027"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"# NOTE(efried): 1.26 is required by nova-scheduler to allow reserving all the"},{"line_number":56,"context_line":"# resource provider\u0027s resources."},{"line_number":57,"context_line":"# NOTE: If you bump this version, remember to update the history"},{"line_number":58,"context_line":"# section in the nova-status man page (doc/source/cli/nova-status)."}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_6ddebe10","line":55,"range":{"start_line":55,"start_character":41,"end_line":55,"end_character":50},"updated":"2018-07-10 20:28:43.000000000","message":"compute","commit_id":"0080ef6c902f9d62187be675462c67569c160696"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4e4a05f9ac975c9216774b9bdf424ed0863d5b4b","unresolved":false,"context_lines":[{"line_number":52,"context_line":"PLACEMENT_DOCS_LINK \u003d \u0027https://docs.openstack.org/nova/latest\u0027 \\"},{"line_number":53,"context_line":"                      \u0027/user/placement.html\u0027"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"# NOTE(efried): 1.26 is required by nova-scheduler to allow reserving all the"},{"line_number":56,"context_line":"# resource provider\u0027s resources."},{"line_number":57,"context_line":"# NOTE: If you bump this version, remember to update the history"},{"line_number":58,"context_line":"# section in the nova-status man page (doc/source/cli/nova-status)."}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_0de14acf","line":55,"range":{"start_line":55,"start_character":7,"end_line":55,"end_character":13},"updated":"2018-07-10 20:28:43.000000000","message":"vdrok","commit_id":"0080ef6c902f9d62187be675462c67569c160696"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6225f30f128866eb0ced4b9c322d508690108dfd","unresolved":false,"context_lines":[{"line_number":52,"context_line":"PLACEMENT_DOCS_LINK \u003d \u0027https://docs.openstack.org/nova/latest\u0027 \\"},{"line_number":53,"context_line":"                      \u0027/user/placement.html\u0027"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"# NOTE(efried): 1.26 is required by nova-scheduler to allow reserving all the"},{"line_number":56,"context_line":"# resource provider\u0027s resources."},{"line_number":57,"context_line":"# NOTE: If you bump this version, remember to update the history"},{"line_number":58,"context_line":"# section in the nova-status man page (doc/source/cli/nova-status)."}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_768840c2","line":55,"range":{"start_line":55,"start_character":41,"end_line":55,"end_character":50},"in_reply_to":"5f7c97a3_6ddebe10","updated":"2018-07-17 13:16:56.000000000","message":"yup will fix","commit_id":"0080ef6c902f9d62187be675462c67569c160696"}],"nova/compute/manager.py":[{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"4cd15b7eeaf395476bd7db4e97bdfe426b3bd3a1","unresolved":false,"context_lines":[{"line_number":742,"context_line":"        rt \u003d self._get_resource_tracker()"},{"line_number":743,"context_line":"        rt.reportclient.delete_allocation_for_instance(context, instance.uuid)"},{"line_number":744,"context_line":""},{"line_number":745,"context_line":"        # Update the resource tracker after the allocation is gone"},{"line_number":746,"context_line":"        self._update_resource_tracker(context, instance)"},{"line_number":747,"context_line":""},{"line_number":748,"context_line":"        self._notify_about_instance_usage(context, instance, \"delete.end\")"}],"source_content_type":"text/x-python","patch_set":4,"id":"9f6a8fd7_c2919c48","line":745,"updated":"2018-04-30 15:38:34.000000000","message":"moving it as in ironic case reserved\u003d1 will be set on a node inventory in this call. doing it before deleting allocation probably blows things up?","commit_id":"f450525639ba961489a5af1d60e07a0e647708d5"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"d9194aef70994e45733d6d6b425bac0d6799fc3c","unresolved":false,"context_lines":[{"line_number":742,"context_line":"        rt \u003d self._get_resource_tracker()"},{"line_number":743,"context_line":"        rt.reportclient.delete_allocation_for_instance(context, instance.uuid)"},{"line_number":744,"context_line":""},{"line_number":745,"context_line":"        # Update the resource tracker after the allocation is gone"},{"line_number":746,"context_line":"        self._update_resource_tracker(context, instance)"},{"line_number":747,"context_line":""},{"line_number":748,"context_line":"        self._notify_about_instance_usage(context, instance, \"delete.end\")"}],"source_content_type":"text/x-python","patch_set":4,"id":"9f6a8fd7_6a92c34d","line":745,"in_reply_to":"9f6a8fd7_c2919c48","updated":"2018-05-02 08:51:39.000000000","message":"It appears we don\u0027t need this:\n\nMay 02 08:42:30 ubuntu devstack@placement-api.service[21128]: WARNING nova.api.openstack.placement.objects.resource_prov\nider [req-604067dd-c30d-4637-b50a-c74d6dd8e1af req-b86ec434-9c7d-4eba-8a77-6faecdcf0b76 service placement] Resource prov\nider 81ee088a-e7a3-4450-8256-8b521739787f is now over-capacity for CUSTOM_BAREMETAL\n\nThis will also save us from having a short period of time when race is possible between deleting an allocation and reserving the inventory","commit_id":"f450525639ba961489a5af1d60e07a0e647708d5"}],"nova/scheduler/client/report.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"9c7c90dea5c9dbc960e5cdc77f9f4a1ed7db6ffc","unresolved":false,"context_lines":[{"line_number":883,"context_line":"        # NOTE(vdrok): in microversion 1.24 it was allowed to have inventory"},{"line_number":884,"context_line":"        # records with reserved value equal to total"},{"line_number":885,"context_line":"        version \u003d \u00271.24\u0027"},{"line_number":886,"context_line":"        result \u003d self.put(url, payload, version\u003dversion,"},{"line_number":887,"context_line":"                          global_request_id\u003dcontext.global_id)"},{"line_number":888,"context_line":"        if result.status_code \u003d\u003d 409:"},{"line_number":889,"context_line":"            LOG.info(\u0027[%(placement_req_id)s] Inventory update conflict for \u0027"},{"line_number":890,"context_line":"                     \u0027%(resource_provider_uuid)s with generation ID \u0027"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f6a8fd7_8d4ac724","line":887,"range":{"start_line":886,"start_character":0,"end_line":887,"end_character":62},"updated":"2018-05-02 16:16:59.000000000","message":"do we need to handle the case when 1.24 is not available?","commit_id":"35cbf06ee4517513627e0a9e5f54c8f81085e179"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f69f9e6c29418eb8ccd32ed60f3a554d7cdb6037","unresolved":false,"context_lines":[{"line_number":883,"context_line":"        # NOTE(vdrok): in microversion 1.24 it was allowed to have inventory"},{"line_number":884,"context_line":"        # records with reserved value equal to total"},{"line_number":885,"context_line":"        version \u003d \u00271.24\u0027"},{"line_number":886,"context_line":"        result \u003d self.put(url, payload, version\u003dversion,"},{"line_number":887,"context_line":"                          global_request_id\u003dcontext.global_id)"},{"line_number":888,"context_line":"        if result.status_code \u003d\u003d 409:"},{"line_number":889,"context_line":"            LOG.info(\u0027[%(placement_req_id)s] Inventory update conflict for \u0027"},{"line_number":890,"context_line":"                     \u0027%(resource_provider_uuid)s with generation ID \u0027"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f6a8fd7_ede903b7","line":887,"range":{"start_line":886,"start_character":0,"end_line":887,"end_character":62},"in_reply_to":"9f6a8fd7_8d4ac724","updated":"2018-05-02 16:26:05.000000000","message":"dunno, placement is still part of nova, but maybe we should","commit_id":"35cbf06ee4517513627e0a9e5f54c8f81085e179"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"afe5e23c39cbe8aab811a5e40e35ff4e5196b53d","unresolved":false,"context_lines":[{"line_number":883,"context_line":"        # NOTE(vdrok): in microversion 1.24 it was allowed to have inventory"},{"line_number":884,"context_line":"        # records with reserved value equal to total"},{"line_number":885,"context_line":"        version \u003d \u00271.24\u0027"},{"line_number":886,"context_line":"        result \u003d self.put(url, payload, version\u003dversion,"},{"line_number":887,"context_line":"                          global_request_id\u003dcontext.global_id)"},{"line_number":888,"context_line":"        if result.status_code \u003d\u003d 409:"},{"line_number":889,"context_line":"            LOG.info(\u0027[%(placement_req_id)s] Inventory update conflict for \u0027"},{"line_number":890,"context_line":"                     \u0027%(resource_provider_uuid)s with generation ID \u0027"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f7c97a3_1d716578","line":887,"range":{"start_line":886,"start_character":0,"end_line":887,"end_character":62},"in_reply_to":"9f6a8fd7_ede903b7","updated":"2018-06-04 18:54:11.000000000","message":"The current rule is that placement should always be upgraded before nova, so we decided that fallback code is not required when talking to placement from nova.","commit_id":"35cbf06ee4517513627e0a9e5f54c8f81085e179"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"39a7139c3cbbcc3f438208f1716e1d48bb8f9ea1","unresolved":false,"context_lines":[{"line_number":859,"context_line":"        url \u003d \u0027/resource_providers/%s/inventories\u0027 % rp_uuid"},{"line_number":860,"context_line":"        # NOTE(vdrok): in microversion 1.26 it was allowed to have inventory"},{"line_number":861,"context_line":"        # records with reserved value equal to total"},{"line_number":862,"context_line":"        version \u003d \u00271.26\u0027"},{"line_number":863,"context_line":"        result \u003d self.put(url, payload, version\u003dversion,"},{"line_number":864,"context_line":"                          global_request_id\u003dcontext.global_id)"},{"line_number":865,"context_line":"        if result.status_code \u003d\u003d 409:"}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_66bc6506","line":862,"range":{"start_line":862,"start_character":8,"end_line":862,"end_character":24},"updated":"2018-06-18 13:44:07.000000000","message":"future cleanup patch: consider adding this version as a constant at the top of this file.","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"1fa9467a782b739160563385e617400ff29abf79","unresolved":false,"context_lines":[{"line_number":859,"context_line":"        url \u003d \u0027/resource_providers/%s/inventories\u0027 % rp_uuid"},{"line_number":860,"context_line":"        # NOTE(vdrok): in microversion 1.26 it was allowed to have inventory"},{"line_number":861,"context_line":"        # records with reserved value equal to total"},{"line_number":862,"context_line":"        version \u003d \u00271.26\u0027"},{"line_number":863,"context_line":"        result \u003d self.put(url, payload, version\u003dversion,"},{"line_number":864,"context_line":"                          global_request_id\u003dcontext.global_id)"},{"line_number":865,"context_line":"        if result.status_code \u003d\u003d 409:"}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_44012104","line":862,"range":{"start_line":862,"start_character":8,"end_line":862,"end_character":24},"in_reply_to":"5f7c97a3_66bc6506","updated":"2018-06-18 14:41:48.000000000","message":"yup","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4e4a05f9ac975c9216774b9bdf424ed0863d5b4b","unresolved":false,"context_lines":[{"line_number":858,"context_line":"            \u0027inventories\u0027: inv_data,"},{"line_number":859,"context_line":"        }"},{"line_number":860,"context_line":"        url \u003d \u0027/resource_providers/%s/inventories\u0027 % rp_uuid"},{"line_number":861,"context_line":"        # NOTE(vdrok): in microversion 1.26 it was allowed to have inventory"},{"line_number":862,"context_line":"        # records with reserved value equal to total"},{"line_number":863,"context_line":"        version \u003d ALLOW_RESERVED_EQUAL_TOTAL_INVENTORY"},{"line_number":864,"context_line":"        result \u003d self.put(url, payload, version\u003dversion,"}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_edc96e50","line":861,"range":{"start_line":861,"start_character":47,"end_line":861,"end_character":50},"updated":"2018-07-10 20:28:43.000000000","message":"is","commit_id":"0080ef6c902f9d62187be675462c67569c160696"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6225f30f128866eb0ced4b9c322d508690108dfd","unresolved":false,"context_lines":[{"line_number":858,"context_line":"            \u0027inventories\u0027: inv_data,"},{"line_number":859,"context_line":"        }"},{"line_number":860,"context_line":"        url \u003d \u0027/resource_providers/%s/inventories\u0027 % rp_uuid"},{"line_number":861,"context_line":"        # NOTE(vdrok): in microversion 1.26 it was allowed to have inventory"},{"line_number":862,"context_line":"        # records with reserved value equal to total"},{"line_number":863,"context_line":"        version \u003d ALLOW_RESERVED_EQUAL_TOTAL_INVENTORY"},{"line_number":864,"context_line":"        result \u003d self.put(url, payload, version\u003dversion,"}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_16bb0c75","line":861,"range":{"start_line":861,"start_character":47,"end_line":861,"end_character":50},"in_reply_to":"5f7c97a3_edc96e50","updated":"2018-07-17 13:16:56.000000000","message":"Done","commit_id":"0080ef6c902f9d62187be675462c67569c160696"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"de736fec4e280bad6c09a99bfb58689121aa1a09","unresolved":false,"context_lines":[{"line_number":49,"context_line":"PLACEMENT_CLIENT_SEMAPHORE \u003d \u0027placement_client\u0027"},{"line_number":50,"context_line":"CONSUMER_GENERATION_VERSION \u003d \u00271.28\u0027"},{"line_number":51,"context_line":"GRANULAR_AC_VERSION \u003d \u00271.25\u0027"},{"line_number":52,"context_line":"ALLOW_RESERVED_EQUAL_TOTAL_INVENTORY \u003d \u00271.26\u0027"},{"line_number":53,"context_line":"POST_RPS_RETURNS_PAYLOAD_API_VERSION \u003d \u00271.20\u0027"},{"line_number":54,"context_line":"AGGREGATE_GENERATION_VERSION \u003d \u00271.19\u0027"},{"line_number":55,"context_line":"NESTED_PROVIDER_API_VERSION \u003d \u00271.14\u0027"}],"source_content_type":"text/x-python","patch_set":15,"id":"5f7c97a3_8988b26b","line":52,"range":{"start_line":52,"start_character":0,"end_line":52,"end_character":36},"updated":"2018-07-24 18:41:23.000000000","message":"nit: include the _VERSION suffix","commit_id":"eeca3bc4574a0375bf25269993eb012a8c4d51b3"}],"nova/tests/unit/virt/ironic/test_driver.py":[{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"39a7139c3cbbcc3f438208f1716e1d48bb8f9ea1","unresolved":false,"context_lines":[{"line_number":375,"context_line":"        self.assertEqual(props[\u0027memory_mb\u0027], result[\u0027memory_mb\u0027])"},{"line_number":376,"context_line":"        self.assertEqual(result[\u0027memory_mb\u0027], result[\u0027memory_mb_used\u0027])"},{"line_number":377,"context_line":"        self.assertEqual(props[\u0027local_gb\u0027], result[\u0027local_gb\u0027])"},{"line_number":378,"context_line":"        self.assertEqual(result[\u0027local_gb\u0027], result[\u0027local_gb_used\u0027])"},{"line_number":379,"context_line":"        self.assertEqual(node_uuid, result[\u0027hypervisor_hostname\u0027])"},{"line_number":380,"context_line":"        self.assertEqual(stats, result[\u0027stats\u0027])"},{"line_number":381,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_265d0dec","line":378,"updated":"2018-06-18 13:44:07.000000000","message":"✓","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"39a7139c3cbbcc3f438208f1716e1d48bb8f9ea1","unresolved":false,"context_lines":[{"line_number":934,"context_line":"    def test_get_inventory_disabled_node(self, mock_nfc, mock_nr,"},{"line_number":935,"context_line":"                                         mock_res_unavail, mock_res_used):"},{"line_number":936,"context_line":"        \"\"\"Ensure that when a node is disabled, that get_inventory() returns"},{"line_number":937,"context_line":"        resources as reserved."},{"line_number":938,"context_line":"        \"\"\""},{"line_number":939,"context_line":"        mock_nr.return_value \u003d {"},{"line_number":940,"context_line":"            \u0027vcpus\u0027: 24,"}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_864e6136","line":937,"range":{"start_line":937,"start_character":8,"end_line":937,"end_character":29},"updated":"2018-06-18 13:44:07.000000000","message":"s/resources as reserved/resources with reserved amounts equal to the total amounts/","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"1fa9467a782b739160563385e617400ff29abf79","unresolved":false,"context_lines":[{"line_number":934,"context_line":"    def test_get_inventory_disabled_node(self, mock_nfc, mock_nr,"},{"line_number":935,"context_line":"                                         mock_res_unavail, mock_res_used):"},{"line_number":936,"context_line":"        \"\"\"Ensure that when a node is disabled, that get_inventory() returns"},{"line_number":937,"context_line":"        resources as reserved."},{"line_number":938,"context_line":"        \"\"\""},{"line_number":939,"context_line":"        mock_nr.return_value \u003d {"},{"line_number":940,"context_line":"            \u0027vcpus\u0027: 24,"}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_a4ab55d5","line":937,"range":{"start_line":937,"start_character":8,"end_line":937,"end_character":29},"in_reply_to":"5f7c97a3_864e6136","updated":"2018-06-18 14:41:48.000000000","message":"will do if need to fix anything","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"39a7139c3cbbcc3f438208f1716e1d48bb8f9ea1","unresolved":false,"context_lines":[{"line_number":943,"context_line":"            \u0027memory_mb_used\u0027: 0,"},{"line_number":944,"context_line":"            \u0027local_gb\u0027: 100,"},{"line_number":945,"context_line":"            \u0027local_gb_used\u0027: 0,"},{"line_number":946,"context_line":"            \u0027resource_class\u0027: \u0027iron-nfv\u0027,"},{"line_number":947,"context_line":"        }"},{"line_number":948,"context_line":""},{"line_number":949,"context_line":"        result \u003d self.driver.get_inventory(mock.sentinel.nodename)"}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_0611f104","line":946,"range":{"start_line":946,"start_character":29,"end_line":946,"end_character":40},"updated":"2018-06-18 13:44:07.000000000","message":"I\u0027m still waiting for one of the Ironic contributors to name a resource class \"Ironman\". Just sayin\u0027.","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"}],"nova/virt/ironic/driver.py":[{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"d9194aef70994e45733d6d6b425bac0d6799fc3c","unresolved":false,"context_lines":[{"line_number":1162,"context_line":"        # update_usages resource tracker call that will happen next"},{"line_number":1163,"context_line":"        # has the up-to-date node view. Calling the _refresh_cache here would"},{"line_number":1164,"context_line":"        # cause requesting the whole node list from ironic."},{"line_number":1165,"context_line":"        self.node_cache[node.uuid] \u003d self._get_node(node.uuid)"},{"line_number":1166,"context_line":""},{"line_number":1167,"context_line":"    def destroy(self, context, instance, network_info,"},{"line_number":1168,"context_line":"                block_device_info\u003dNone, destroy_disks\u003dTrue):"}],"source_content_type":"text/x-python","patch_set":4,"id":"9f6a8fd7_caa2ef9a","line":1165,"updated":"2018-05-02 08:51:39.000000000","message":"I think here it\u0027s be better to either pop it or make caching time to be per-node and set it as well","commit_id":"f450525639ba961489a5af1d60e07a0e647708d5"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"9c7c90dea5c9dbc960e5cdc77f9f4a1ed7db6ffc","unresolved":false,"context_lines":[{"line_number":821,"context_line":"        \"\"\"Returns a node from the cache, retrieving the node from Ironic API"},{"line_number":822,"context_line":"        if the node doesn\u0027t yet exist in the cache."},{"line_number":823,"context_line":"        \"\"\""},{"line_number":824,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node_uuid)"},{"line_number":825,"context_line":"        def _sync_node_from_cache():"},{"line_number":826,"context_line":"            cache_age \u003d time.time() - self.node_cache_time"},{"line_number":827,"context_line":"            if node_uuid in self.node_cache:"},{"line_number":828,"context_line":"                LOG.debug(\"Using cache for node %(node)s, age: %(age)s\","}],"source_content_type":"text/x-python","patch_set":5,"id":"9f6a8fd7_ad6eab93","line":825,"range":{"start_line":824,"start_character":0,"end_line":825,"end_character":36},"updated":"2018-05-02 16:16:59.000000000","message":"unrelated fix? maybe move to a separate patch?","commit_id":"35cbf06ee4517513627e0a9e5f54c8f81085e179"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"9c7c90dea5c9dbc960e5cdc77f9f4a1ed7db6ffc","unresolved":false,"context_lines":[{"line_number":1161,"context_line":"        timer \u003d loopingcall.FixedIntervalLoopingCall(_wait_for_provision_state)"},{"line_number":1162,"context_line":"        timer.start(interval\u003dCONF.ironic.api_retry_interval).wait()"},{"line_number":1163,"context_line":""},{"line_number":1164,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node.uuid)"},{"line_number":1165,"context_line":"        def _sync_remove_cache_entry():"},{"line_number":1166,"context_line":"            # NOTE(vdrok): Force the cache update, so that"},{"line_number":1167,"context_line":"            # update_usages resource tracker call that will happen next"},{"line_number":1168,"context_line":"            # has the up-to-date node view."}],"source_content_type":"text/x-python","patch_set":5,"id":"9f6a8fd7_4d6d8f96","line":1165,"range":{"start_line":1164,"start_character":0,"end_line":1165,"end_character":39},"updated":"2018-05-02 16:16:59.000000000","message":"ditto?","commit_id":"35cbf06ee4517513627e0a9e5f54c8f81085e179"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f69f9e6c29418eb8ccd32ed60f3a554d7cdb6037","unresolved":false,"context_lines":[{"line_number":1161,"context_line":"        timer \u003d loopingcall.FixedIntervalLoopingCall(_wait_for_provision_state)"},{"line_number":1162,"context_line":"        timer.start(interval\u003dCONF.ironic.api_retry_interval).wait()"},{"line_number":1163,"context_line":""},{"line_number":1164,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node.uuid)"},{"line_number":1165,"context_line":"        def _sync_remove_cache_entry():"},{"line_number":1166,"context_line":"            # NOTE(vdrok): Force the cache update, so that"},{"line_number":1167,"context_line":"            # update_usages resource tracker call that will happen next"},{"line_number":1168,"context_line":"            # has the up-to-date node view."}],"source_content_type":"text/x-python","patch_set":5,"id":"9f6a8fd7_8d272713","line":1165,"range":{"start_line":1164,"start_character":0,"end_line":1165,"end_character":39},"in_reply_to":"9f6a8fd7_4d6d8f96","updated":"2018-05-02 16:26:05.000000000","message":"These are related, in case _refresh_cache in periodic task happens simultaneously with instance deletion, to avoid KeyError on L830 if this pop happens between lines 827 and 830 (or is it not possible with eventlet? I thought switch might happen even during logging)","commit_id":"35cbf06ee4517513627e0a9e5f54c8f81085e179"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"353885c0b82563ec16a5f0419776616432689864","unresolved":false,"context_lines":[{"line_number":1161,"context_line":"        timer \u003d loopingcall.FixedIntervalLoopingCall(_wait_for_provision_state)"},{"line_number":1162,"context_line":"        timer.start(interval\u003dCONF.ironic.api_retry_interval).wait()"},{"line_number":1163,"context_line":""},{"line_number":1164,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node.uuid)"},{"line_number":1165,"context_line":"        def _sync_remove_cache_entry():"},{"line_number":1166,"context_line":"            # NOTE(vdrok): Force the cache update, so that"},{"line_number":1167,"context_line":"            # update_usages resource tracker call that will happen next"},{"line_number":1168,"context_line":"            # has the up-to-date node view."}],"source_content_type":"text/x-python","patch_set":5,"id":"9f6a8fd7_70b3884e","line":1165,"range":{"start_line":1164,"start_character":0,"end_line":1165,"end_character":39},"in_reply_to":"9f6a8fd7_8d272713","updated":"2018-05-02 16:39:37.000000000","message":"err, s/_refresh_cache/_node_from_cache","commit_id":"35cbf06ee4517513627e0a9e5f54c8f81085e179"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"39a7139c3cbbcc3f438208f1716e1d48bb8f9ea1","unresolved":false,"context_lines":[{"line_number":818,"context_line":"        \"\"\"Returns a node from the cache, retrieving the node from Ironic API"},{"line_number":819,"context_line":"        if the node doesn\u0027t yet exist in the cache."},{"line_number":820,"context_line":"        \"\"\""},{"line_number":821,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node_uuid)"},{"line_number":822,"context_line":"        def _sync_node_from_cache():"},{"line_number":823,"context_line":"            cache_age \u003d time.time() - self.node_cache_time"},{"line_number":824,"context_line":"            if node_uuid in self.node_cache:"},{"line_number":825,"context_line":"                LOG.debug(\"Using cache for node %(node)s, age: %(age)s\","},{"line_number":826,"context_line":"                          {\u0027node\u0027: node_uuid, \u0027age\u0027: cache_age})"},{"line_number":827,"context_line":"                return self.node_cache[node_uuid]"},{"line_number":828,"context_line":"            else:"},{"line_number":829,"context_line":"                LOG.debug(\"Node %(node)s not found in cache, age: %(age)s\","},{"line_number":830,"context_line":"                          {\u0027node\u0027: node_uuid, \u0027age\u0027: cache_age})"},{"line_number":831,"context_line":"                node \u003d self._get_node(node_uuid)"},{"line_number":832,"context_line":"                self.node_cache[node_uuid] \u003d node"},{"line_number":833,"context_line":"                return node"},{"line_number":834,"context_line":"        return _sync_node_from_cache()"},{"line_number":835,"context_line":""},{"line_number":836,"context_line":"    def get_info(self, instance):"},{"line_number":837,"context_line":"        \"\"\"Get the current state and resource usage for this instance."}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_e68075fa","line":834,"range":{"start_line":821,"start_character":0,"end_line":834,"end_character":38},"updated":"2018-06-18 13:44:07.000000000","message":"This probably could have been done in a separate patch. I\u0027m curious what was it about *this* patch that caused you to place this locking protection over the cache get?","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"1fa9467a782b739160563385e617400ff29abf79","unresolved":false,"context_lines":[{"line_number":818,"context_line":"        \"\"\"Returns a node from the cache, retrieving the node from Ironic API"},{"line_number":819,"context_line":"        if the node doesn\u0027t yet exist in the cache."},{"line_number":820,"context_line":"        \"\"\""},{"line_number":821,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node_uuid)"},{"line_number":822,"context_line":"        def _sync_node_from_cache():"},{"line_number":823,"context_line":"            cache_age \u003d time.time() - self.node_cache_time"},{"line_number":824,"context_line":"            if node_uuid in self.node_cache:"},{"line_number":825,"context_line":"                LOG.debug(\"Using cache for node %(node)s, age: %(age)s\","},{"line_number":826,"context_line":"                          {\u0027node\u0027: node_uuid, \u0027age\u0027: cache_age})"},{"line_number":827,"context_line":"                return self.node_cache[node_uuid]"},{"line_number":828,"context_line":"            else:"},{"line_number":829,"context_line":"                LOG.debug(\"Node %(node)s not found in cache, age: %(age)s\","},{"line_number":830,"context_line":"                          {\u0027node\u0027: node_uuid, \u0027age\u0027: cache_age})"},{"line_number":831,"context_line":"                node \u003d self._get_node(node_uuid)"},{"line_number":832,"context_line":"                self.node_cache[node_uuid] \u003d node"},{"line_number":833,"context_line":"                return node"},{"line_number":834,"context_line":"        return _sync_node_from_cache()"},{"line_number":835,"context_line":""},{"line_number":836,"context_line":"    def get_info(self, instance):"},{"line_number":837,"context_line":"        \"\"\"Get the current state and resource usage for this instance."}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_c43a11c3","line":834,"range":{"start_line":821,"start_character":0,"end_line":834,"end_character":38},"in_reply_to":"5f7c97a3_e68075fa","updated":"2018-06-18 14:41:48.000000000","message":"yup, replied in the next comment","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"39a7139c3cbbcc3f438208f1716e1d48bb8f9ea1","unresolved":false,"context_lines":[{"line_number":1158,"context_line":"        timer \u003d loopingcall.FixedIntervalLoopingCall(_wait_for_provision_state)"},{"line_number":1159,"context_line":"        timer.start(interval\u003dCONF.ironic.api_retry_interval).wait()"},{"line_number":1160,"context_line":""},{"line_number":1161,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node.uuid)"},{"line_number":1162,"context_line":"        def _sync_remove_cache_entry():"},{"line_number":1163,"context_line":"            # NOTE(vdrok): Force the cache update, so that"},{"line_number":1164,"context_line":"            # update_usages resource tracker call that will happen next"},{"line_number":1165,"context_line":"            # has the up-to-date node view."}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_c677793b","line":1162,"range":{"start_line":1161,"start_character":8,"end_line":1162,"end_character":39},"updated":"2018-06-18 13:44:07.000000000","message":"similar comment to above. I\u0027m not against this lock protection. Just curious what about this particular patch caused you to add it in this patch.","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"1fa9467a782b739160563385e617400ff29abf79","unresolved":false,"context_lines":[{"line_number":1158,"context_line":"        timer \u003d loopingcall.FixedIntervalLoopingCall(_wait_for_provision_state)"},{"line_number":1159,"context_line":"        timer.start(interval\u003dCONF.ironic.api_retry_interval).wait()"},{"line_number":1160,"context_line":""},{"line_number":1161,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node.uuid)"},{"line_number":1162,"context_line":"        def _sync_remove_cache_entry():"},{"line_number":1163,"context_line":"            # NOTE(vdrok): Force the cache update, so that"},{"line_number":1164,"context_line":"            # update_usages resource tracker call that will happen next"},{"line_number":1165,"context_line":"            # has the up-to-date node view."}],"source_content_type":"text/x-python","patch_set":10,"id":"5f7c97a3_e4538d15","line":1162,"range":{"start_line":1161,"start_character":8,"end_line":1162,"end_character":39},"in_reply_to":"5f7c97a3_c677793b","updated":"2018-06-18 14:41:48.000000000","message":"previously the only code path that was touching node_cache was the resource tracker update, but now it happens during _unprovision as well, so decided to add this just in case.","commit_id":"1c44eefcd511750d521f204ff80021a0b4a2ff2f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4e4a05f9ac975c9216774b9bdf424ed0863d5b4b","unresolved":false,"context_lines":[{"line_number":821,"context_line":"        \"\"\"Returns a node from the cache, retrieving the node from Ironic API"},{"line_number":822,"context_line":"        if the node doesn\u0027t yet exist in the cache."},{"line_number":823,"context_line":"        \"\"\""},{"line_number":824,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node_uuid)"},{"line_number":825,"context_line":"        def _sync_node_from_cache():"},{"line_number":826,"context_line":"            cache_age \u003d time.time() - self.node_cache_time"},{"line_number":827,"context_line":"            if node_uuid in self.node_cache:"}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_6d7a3ef0","line":824,"updated":"2018-07-10 20:28:43.000000000","message":"This seems like an unrelated change that could be in a separate patch - is there something about using 1.26 for reporting totally reserved inventory the requires this locking now?","commit_id":"0080ef6c902f9d62187be675462c67569c160696"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"00d7110fa7ff61dfff1090f5cf12ea498512eb3a","unresolved":false,"context_lines":[{"line_number":821,"context_line":"        \"\"\"Returns a node from the cache, retrieving the node from Ironic API"},{"line_number":822,"context_line":"        if the node doesn\u0027t yet exist in the cache."},{"line_number":823,"context_line":"        \"\"\""},{"line_number":824,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node_uuid)"},{"line_number":825,"context_line":"        def _sync_node_from_cache():"},{"line_number":826,"context_line":"            cache_age \u003d time.time() - self.node_cache_time"},{"line_number":827,"context_line":"            if node_uuid in self.node_cache:"}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_b03941f2","line":824,"in_reply_to":"5f7c97a3_6d7a3ef0","updated":"2018-07-13 15:14:19.000000000","message":"+1","commit_id":"0080ef6c902f9d62187be675462c67569c160696"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6225f30f128866eb0ced4b9c322d508690108dfd","unresolved":false,"context_lines":[{"line_number":821,"context_line":"        \"\"\"Returns a node from the cache, retrieving the node from Ironic API"},{"line_number":822,"context_line":"        if the node doesn\u0027t yet exist in the cache."},{"line_number":823,"context_line":"        \"\"\""},{"line_number":824,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node_uuid)"},{"line_number":825,"context_line":"        def _sync_node_from_cache():"},{"line_number":826,"context_line":"            cache_age \u003d time.time() - self.node_cache_time"},{"line_number":827,"context_line":"            if node_uuid in self.node_cache:"}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_79127157","line":824,"in_reply_to":"5f7c97a3_b03941f2","updated":"2018-07-17 13:16:56.000000000","message":"yeah I commented on that earlier, prior to this change node_cache could only be modified during get_available_resource execution, now we also modify it during instance termination. i think without this locking KeyError could happen during get_available_resource if instance termination gets executed simultaneously with get_available_resource for this node. I can add a comment in code so that it is more visible","commit_id":"0080ef6c902f9d62187be675462c67569c160696"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"cd59b87e588064bf603ae497adad1f417fc88ba7","unresolved":false,"context_lines":[{"line_number":823,"context_line":"        \"\"\""},{"line_number":824,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node_uuid)"},{"line_number":825,"context_line":"        def _sync_node_from_cache():"},{"line_number":826,"context_line":"            cache_age \u003d time.time() - self.node_cache_time"},{"line_number":827,"context_line":"            if node_uuid in self.node_cache:"},{"line_number":828,"context_line":"                LOG.debug(\"Using cache for node %(node)s, age: %(age)s\","},{"line_number":829,"context_line":"                          {\u0027node\u0027: node_uuid, \u0027age\u0027: cache_age})"}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_572a75e6","line":826,"updated":"2018-06-27 13:01:24.000000000","message":"Seems interesting that we\u0027re only logging cache_age, not using it as a threshold...","commit_id":"0080ef6c902f9d62187be675462c67569c160696"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6225f30f128866eb0ced4b9c322d508690108dfd","unresolved":false,"context_lines":[{"line_number":823,"context_line":"        \"\"\""},{"line_number":824,"context_line":"        @utils.synchronized(\u0027ironic-node-%s\u0027 % node_uuid)"},{"line_number":825,"context_line":"        def _sync_node_from_cache():"},{"line_number":826,"context_line":"            cache_age \u003d time.time() - self.node_cache_time"},{"line_number":827,"context_line":"            if node_uuid in self.node_cache:"},{"line_number":828,"context_line":"                LOG.debug(\"Using cache for node %(node)s, age: %(age)s\","},{"line_number":829,"context_line":"                          {\u0027node\u0027: node_uuid, \u0027age\u0027: cache_age})"}],"source_content_type":"text/x-python","patch_set":13,"id":"5f7c97a3_d665941d","line":826,"in_reply_to":"5f7c97a3_572a75e6","updated":"2018-07-17 13:16:56.000000000","message":"yeah","commit_id":"0080ef6c902f9d62187be675462c67569c160696"}]}
