)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":9555,"name":"Matthew Booth","email":"mbooth@redhat.com","username":"MatthewBooth"},"change_message_id":"a23a31c173b81c787303c602e13859abb680ca8a","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"WIP compute: Take an instance.uuid lock when rebooting"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Previously simultaneous requests to reboot and delete an instance could"},{"line_number":10,"context_line":"race as only the latter took a lock against the uuid of the instance."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"With the Libvirt driver this race could potentially result in attempts"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"7faddb67_7fd833ee","line":9,"range":{"start_line":9,"start_character":11,"end_line":9,"end_character":65},"updated":"2019-07-30 13:40:03.000000000","message":"A (very quick and casual) audit suggests that none of the following compute host instance operations take an instance lock:\n\nstart\nsoft_delete\nrestore\nrebuild\nreboot\nbackup\nsnapshot\nset_admin_password\ninject_file\nrescue\nunrescue\nrevert_resize\nresize\npause\nunpause\nsuspend\nresume\n\nI believe this means they can all race on the compute host with delete. Several of these are highly likely to have undesirable interactions. I suggest locking them all might be in order.\n\nHow about an @instance_lock decorator in compute manager, applied across the board?","commit_id":"1fd9c2a0ec80d90c494a6e772e0d96cb23088465"}],"nova/compute/manager.py":[{"author":{"_account_id":10135,"name":"Lee Yarwood","display_name":"Lee Yarwood","email":"lyarwood@redhat.com","username":"lyarwood"},"change_message_id":"d0c730c44f7db2daa5a1f158a1668e4a3d7c8367","unresolved":false,"context_lines":[{"line_number":3449,"context_line":"    def reboot_instance(self, context, instance, block_device_info,"},{"line_number":3450,"context_line":"                        reboot_type):"},{"line_number":3451,"context_line":"        @utils.synchronized(instance.uuid)"},{"line_number":3452,"context_line":"        def do_reboot_instance(context, instance, block_device_info, "},{"line_number":3453,"context_line":"                               reboot_type):"},{"line_number":3454,"context_line":"            self._reboot_instance(context, instance, block_device_info,"},{"line_number":3455,"context_line":"                                  reboot_type)"}],"source_content_type":"text/x-python","patch_set":2,"id":"7faddb67_7c3e01b9","line":3452,"updated":"2019-07-30 11:00:53.000000000","message":"gah, I\u0027ll fix this in a respin once I\u0027ve decided how to test this.","commit_id":"1fd9c2a0ec80d90c494a6e772e0d96cb23088465"}]}
