)]}'
{"nova/compute/manager.py":[{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"e17442d1ec989286b7eca6d7e09fb1666a4a3bf8","unresolved":false,"context_lines":[{"line_number":2502,"context_line":"        instance.save()"},{"line_number":2503,"context_line":"        instance.destroy()"},{"line_number":2504,"context_line":""},{"line_number":2505,"context_line":"        try:"},{"line_number":2506,"context_line":"            instance_group \u003d objects.InstanceGroup.get_by_instance_uuid("},{"line_number":2507,"context_line":"                context, instance.uuid)"},{"line_number":2508,"context_line":"            LOG.info(\u0027Removing instance group member from database for \u0027"},{"line_number":2509,"context_line":"                     \u0027instance\u0027, instance\u003dinstance)"},{"line_number":2510,"context_line":"            objects.InstanceGroup._remove_members_in_db("},{"line_number":2511,"context_line":"                context, instance_group.id, [instance.uuid])"},{"line_number":2512,"context_line":"        except exception.InstanceGroupNotFound:"},{"line_number":2513,"context_line":"            pass"},{"line_number":2514,"context_line":""},{"line_number":2515,"context_line":"        self._complete_deletion(context,"},{"line_number":2516,"context_line":"                                instance,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f7c97a3_918c6b3a","line":2513,"range":{"start_line":2505,"start_character":8,"end_line":2513,"end_character":16},"updated":"2018-07-12 11:47:06.000000000","message":"Hmm, the context here must been targeted to the cell db, but the instance_group table is in api_db.","commit_id":"e88a331b083fff454e86ee35549286d29d29c483"},{"author":{"_account_id":25562,"name":"Chen","email":"dstbtgagt@foxmail.com","username":"chenn2"},"change_message_id":"8c507a002d60dc591b019c2efe0cbde8d0019455","unresolved":false,"context_lines":[{"line_number":2502,"context_line":"        instance.save()"},{"line_number":2503,"context_line":"        instance.destroy()"},{"line_number":2504,"context_line":""},{"line_number":2505,"context_line":"        try:"},{"line_number":2506,"context_line":"            instance_group \u003d objects.InstanceGroup.get_by_instance_uuid("},{"line_number":2507,"context_line":"                context, instance.uuid)"},{"line_number":2508,"context_line":"            LOG.info(\u0027Removing instance group member from database for \u0027"},{"line_number":2509,"context_line":"                     \u0027instance\u0027, instance\u003dinstance)"},{"line_number":2510,"context_line":"            objects.InstanceGroup._remove_members_in_db("},{"line_number":2511,"context_line":"                context, instance_group.id, [instance.uuid])"},{"line_number":2512,"context_line":"        except exception.InstanceGroupNotFound:"},{"line_number":2513,"context_line":"            pass"},{"line_number":2514,"context_line":""},{"line_number":2515,"context_line":"        self._complete_deletion(context,"},{"line_number":2516,"context_line":"                                instance,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f7c97a3_86097385","line":2513,"range":{"start_line":2505,"start_character":8,"end_line":2513,"end_character":16},"in_reply_to":"5f7c97a3_918c6b3a","updated":"2018-07-13 09:46:55.000000000","message":"makes sense. then what i can think of is moving it to the scheduler side","commit_id":"e88a331b083fff454e86ee35549286d29d29c483"}],"nova/scheduler/manager.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"5edc83133ad874203d53d2448a497aae796cef8d","unresolved":false,"context_lines":[{"line_number":200,"context_line":"        self.driver.host_manager.update_instance_info(context, host_name,"},{"line_number":201,"context_line":"                                                      instance_info)"},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"    def delete_instance_info(self, context, host_name, instance_uuid):"},{"line_number":204,"context_line":"        \"\"\"Receives information about the deletion of one of a host\u0027s"},{"line_number":205,"context_line":"        instances, and updates the driver\u0027s HostManager with that information."},{"line_number":206,"context_line":"        If the instance is associcated with a group, also removes its member"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_c99e8c62","line":203,"updated":"2018-08-08 22:53:26.000000000","message":"This won\u0027t be called if track_instance_changes if False in nova.conf, which it will be if people are doing a split-MQ multi-cell deployment. Plus, this just isn\u0027t really where we clean stuff up like this, including requests specs and instance mappings. See https://review.openstack.org/#/c/588943/ for the pattern we\u0027ve been using.","commit_id":"bb75e3b4068d3dc2a23635074a04f931f118e058"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"5ee7f03b83ad0efb0e416bb7b100f9bb0bc03823","unresolved":false,"context_lines":[{"line_number":200,"context_line":"        self.driver.host_manager.update_instance_info(context, host_name,"},{"line_number":201,"context_line":"                                                      instance_info)"},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"    def delete_instance_info(self, context, host_name, instance_uuid):"},{"line_number":204,"context_line":"        \"\"\"Receives information about the deletion of one of a host\u0027s"},{"line_number":205,"context_line":"        instances, and updates the driver\u0027s HostManager with that information."},{"line_number":206,"context_line":"        If the instance is associcated with a group, also removes its member"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_5b9229a0","line":203,"in_reply_to":"3f79a3b5_5a70f8dc","updated":"2018-08-09 16:57:41.000000000","message":"\u003e But here don\u0027t we have to make a upcall from compute to api db, which will violate api/cell isolation rules. Is there any workaround in this case?\n\nNo, nova-manage is pretty special in that it\u0027s admin-only and not generally something anyone is going to run on a compute host unless the commands are specific for hitting the nova-compute code somehow. nova-manage is really meant to be run on the controller (which has access to the nova_api DB) or in a venv/container which is fully configured for the controller as well.","commit_id":"bb75e3b4068d3dc2a23635074a04f931f118e058"},{"author":{"_account_id":25562,"name":"Chen","email":"dstbtgagt@foxmail.com","username":"chenn2"},"change_message_id":"3e439b3cd3eadf40fadb95aa02c59d95acfa989a","unresolved":false,"context_lines":[{"line_number":200,"context_line":"        self.driver.host_manager.update_instance_info(context, host_name,"},{"line_number":201,"context_line":"                                                      instance_info)"},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"    def delete_instance_info(self, context, host_name, instance_uuid):"},{"line_number":204,"context_line":"        \"\"\"Receives information about the deletion of one of a host\u0027s"},{"line_number":205,"context_line":"        instances, and updates the driver\u0027s HostManager with that information."},{"line_number":206,"context_line":"        If the instance is associcated with a group, also removes its member"}],"source_content_type":"text/x-python","patch_set":5,"id":"3f79a3b5_5a70f8dc","line":203,"in_reply_to":"3f79a3b5_c99e8c62","updated":"2018-08-09 04:13:41.000000000","message":"I checked out the latest pattern. It seems nova-manage trying to query api db is totally fine. But here don\u0027t we have to make a upcall from compute to api db, which will violate api/cell isolation rules. Is there any workaround in this case?","commit_id":"bb75e3b4068d3dc2a23635074a04f931f118e058"}]}
