)]}'
{"nova/compute/resource_tracker.py":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"b59a51fe8844166cd548c277163cdc624cbc90a0","unresolved":false,"context_lines":[{"line_number":853,"context_line":"            if instance.vm_state not in vm_states.ALLOW_RESOURCE_REMOVAL:"},{"line_number":854,"context_line":"                self._update_usage_from_instance(context, instance)"},{"line_number":855,"context_line":"        self.compute_node.free_ram_mb \u003d max(0, self.compute_node.free_ram_mb)"},{"line_number":856,"context_line":"        self.compute_node.free_disk_gb \u003d max(0, self.compute_node.free_disk_gb)"},{"line_number":857,"context_line":""},{"line_number":858,"context_line":"    def _find_orphaned_instances(self):"},{"line_number":859,"context_line":"        \"\"\"Given the set of instances and migrations already account for"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a122d0e_d34c7944","line":856,"updated":"2016-04-19 09:25:19.000000000","message":"I think I understand the reason of the core of the change (from elif to if) but I don\u0027t really find why we also need to avoid negative values here. How this is related to the bugfix?","commit_id":"016b810f675b20e8ce78f4c82dc9c679c0162b7a"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"c9d01797b4533546c169dad9b1ec6b153ee4fae5","unresolved":false,"context_lines":[{"line_number":853,"context_line":"            if instance.vm_state not in vm_states.ALLOW_RESOURCE_REMOVAL:"},{"line_number":854,"context_line":"                self._update_usage_from_instance(context, instance)"},{"line_number":855,"context_line":"        self.compute_node.free_ram_mb \u003d max(0, self.compute_node.free_ram_mb)"},{"line_number":856,"context_line":"        self.compute_node.free_disk_gb \u003d max(0, self.compute_node.free_disk_gb)"},{"line_number":857,"context_line":""},{"line_number":858,"context_line":"    def _find_orphaned_instances(self):"},{"line_number":859,"context_line":"        \"\"\"Given the set of instances and migrations already account for"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a122d0e_7bb8f811","line":856,"in_reply_to":"1a122d0e_8a9c695e","updated":"2016-05-04 09:06:49.000000000","message":"Thanks! It makes sense now. :)","commit_id":"016b810f675b20e8ce78f4c82dc9c679c0162b7a"},{"author":{"_account_id":11642,"name":"Jesse J. Cook","email":"jesse.cook@rackspace.com","username":"crashenx"},"change_message_id":"aa28a3c6728a0c06053374b439967de86e274908","unresolved":false,"context_lines":[{"line_number":853,"context_line":"            if instance.vm_state not in vm_states.ALLOW_RESOURCE_REMOVAL:"},{"line_number":854,"context_line":"                self._update_usage_from_instance(context, instance)"},{"line_number":855,"context_line":"        self.compute_node.free_ram_mb \u003d max(0, self.compute_node.free_ram_mb)"},{"line_number":856,"context_line":"        self.compute_node.free_disk_gb \u003d max(0, self.compute_node.free_disk_gb)"},{"line_number":857,"context_line":""},{"line_number":858,"context_line":"    def _find_orphaned_instances(self):"},{"line_number":859,"context_line":"        \"\"\"Given the set of instances and migrations already account for"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a122d0e_8a9c695e","line":856,"in_reply_to":"1a122d0e_d34c7944","updated":"2016-04-19 17:59:29.000000000","message":"Excellent question!\n\nSorry if this comes out not fixed width and is hard to read. PiN \u003d\u003d provisioned in Nova, PiI \u003d\u003d provisioned in Ironic.\n\n\nHow it works now (broken nodes can be scheduled to):\nBroke  PiN  PiI  UsedMem  AvailMem  Reported\n    Y    Y    Y      100       100         0\n    Y    Y    N      100       100         0\n    Y    N    Y        0       100       100\n    Y    N    N        0         0         0\n\nThe change (broken nodes cannot be scheduled to):\nBroke  PiN  PiI  UsedMem  AvailMem  Reported\n    Y    Y    Y      100         0      -100 -\u003e 0\n    Y    Y    N      100         0      -100 -\u003e 0\n    Y    N    Y        0         0         0\n    Y    N    N        0         0         0\n\nThe resource tracker ultimately determined the used memory based\non it\u0027s view of instances on nodes. Whereas, Ironic or, afaik, the\nhypervisor determine the available memory.\n\nBack to your question, the node is not overcommitted, it\u0027s\nunavailable. The reported memory should be 0. I think we want to\navoid negative memory because of what\u0027s described here:\nhttps://bugs.launchpad.net/nova/+bug/1502177 . At a minimum, we\nneed it in the cells reporting or half the nodes being broken\ncould prevent scheduling to the cell altogether.","commit_id":"016b810f675b20e8ce78f4c82dc9c679c0162b7a"}],"nova/virt/ironic/driver.py":[{"author":{"_account_id":20223,"name":"zhaolihui","email":"zhaolh@awcloud.com","username":"zhaolihui"},"change_message_id":"52685e3504ad581863ccb54a6e5fc5e7b8c11269","unresolved":false,"context_lines":[{"line_number":310,"context_line":"            vcpus_used \u003d vcpus \u003d instance_info[\u0027vcpus\u0027]"},{"line_number":311,"context_line":"            memory_mb_used \u003d memory_mb \u003d instance_info[\u0027memory_mb\u0027]"},{"line_number":312,"context_line":"            local_gb_used \u003d local_gb \u003d instance_info[\u0027local_gb\u0027]"},{"line_number":313,"context_line":"        if self._node_resources_unavailable(node):"},{"line_number":314,"context_line":"            # The node\u0027s current state is such that it should not present any"},{"line_number":315,"context_line":"            # of its resources to Nova"},{"line_number":316,"context_line":"            vcpus \u003d 0"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_cc938fa2","line":313,"range":{"start_line":313,"start_character":8,"end_line":313,"end_character":50},"updated":"2016-04-16 07:14:39.000000000","message":"suggest that leave it as it is","commit_id":"d8c0e8315b23152e0d21b9ae16d6e0146bd39f8f"},{"author":{"_account_id":11642,"name":"Jesse J. Cook","email":"jesse.cook@rackspace.com","username":"crashenx"},"change_message_id":"05c5a6eeeb8647ce3174404657c92651055d7984","unresolved":false,"context_lines":[{"line_number":310,"context_line":"            vcpus_used \u003d vcpus \u003d instance_info[\u0027vcpus\u0027]"},{"line_number":311,"context_line":"            memory_mb_used \u003d memory_mb \u003d instance_info[\u0027memory_mb\u0027]"},{"line_number":312,"context_line":"            local_gb_used \u003d local_gb \u003d instance_info[\u0027local_gb\u0027]"},{"line_number":313,"context_line":"        if self._node_resources_unavailable(node):"},{"line_number":314,"context_line":"            # The node\u0027s current state is such that it should not present any"},{"line_number":315,"context_line":"            # of its resources to Nova"},{"line_number":316,"context_line":"            vcpus \u003d 0"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_65a176a3","line":313,"range":{"start_line":313,"start_character":8,"end_line":313,"end_character":50},"in_reply_to":"1a122d0e_a0aee182","updated":"2016-04-18 19:11:00.000000000","message":"Done","commit_id":"d8c0e8315b23152e0d21b9ae16d6e0146bd39f8f"},{"author":{"_account_id":2889,"name":"Aeva Black","email":"aeva.online@gmail.com","username":"tenbrae"},"change_message_id":"6b0d5f2e9aea1fb319a395c62e7b3dc0a6a8c451","unresolved":false,"context_lines":[{"line_number":310,"context_line":"            vcpus_used \u003d vcpus \u003d instance_info[\u0027vcpus\u0027]"},{"line_number":311,"context_line":"            memory_mb_used \u003d memory_mb \u003d instance_info[\u0027memory_mb\u0027]"},{"line_number":312,"context_line":"            local_gb_used \u003d local_gb \u003d instance_info[\u0027local_gb\u0027]"},{"line_number":313,"context_line":"        if self._node_resources_unavailable(node):"},{"line_number":314,"context_line":"            # The node\u0027s current state is such that it should not present any"},{"line_number":315,"context_line":"            # of its resources to Nova"},{"line_number":316,"context_line":"            vcpus \u003d 0"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_a0aee182","line":313,"range":{"start_line":313,"start_character":8,"end_line":313,"end_character":50},"in_reply_to":"1a122d0e_cc938fa2","updated":"2016-04-18 17:34:26.000000000","message":"this is a very important part of this change/bugfix -- replacing the \u0027elif\u0027 with \u0027if\u0027 allows us to catch the case where nova thinks there are available resources on the Node, but Ironic does not (because it is not in a usable state).\n\nPlease add a comment here along with this change, and a link to the bug, for future reference.","commit_id":"d8c0e8315b23152e0d21b9ae16d6e0146bd39f8f"}]}
