)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"826a76eaddba97651985ad655f14ece9214f66a1","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"To fix this, upon a failed termination set the vm_state to error and"},{"line_number":22,"context_line":"revert the task_state. This is a partial revert of"},{"line_number":23,"context_line":"I55742203bdd071c7df90902868e46c2020f799bd."},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"Change-Id: I55742203bdd071c7df90902868e46c2020f799bd"},{"line_number":26,"context_line":"Closes-Bug: #1329559"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1ae5cdf2_4275f8ca","line":23,"updated":"2014-06-16 16:10:32.000000000","message":"You referred to your own change in this change... :(","commit_id":"f33a25a3c40722644c774395b38fd7a7ed0246e1"},{"author":{"_account_id":1849,"name":"Joe Gordon","email":"joe.gordon0@gmail.com","username":"jogo"},"change_message_id":"97a914134d5a778ce975b877676d232d330bd1b5","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"To fix this, upon a failed termination set the vm_state to error and"},{"line_number":22,"context_line":"revert the task_state. This is a partial revert of"},{"line_number":23,"context_line":"I55742203bdd071c7df90902868e46c2020f799bd."},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"Change-Id: I55742203bdd071c7df90902868e46c2020f799bd"},{"line_number":26,"context_line":"Closes-Bug: #1329559"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1ae5cdf2_a55de617","line":23,"in_reply_to":"1ae5cdf2_4275f8ca","updated":"2014-06-16 16:15:35.000000000","message":"hehe this should have been: I5fb1bbd56035792f566a6e076edfe7a69df006ef","commit_id":"f33a25a3c40722644c774395b38fd7a7ed0246e1"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f89e81be76b2f718acf796150f9b036b97a830ef","unresolved":false,"context_lines":[{"line_number":23,"context_line":"I55742203bdd071c7df90902868e46c2020f799bd."},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"Change-Id: I55742203bdd071c7df90902868e46c2020f799bd"},{"line_number":26,"context_line":"Closes-Bug: #1329559"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1ae5cdf2_a5188676","line":26,"updated":"2014-06-16 16:13:19.000000000","message":"The original bug for the issue that I always used to track this was bug 1299139.  I\u0027ll just dupe that against this one, we should definitely backport this change though.","commit_id":"f33a25a3c40722644c774395b38fd7a7ed0246e1"}],"nova/compute/api.py":[{"author":{"_account_id":4190,"name":"lifeless","email":"robertc@robertcollins.net","username":"lifeless"},"change_message_id":"1696a589defe85e258ae21d4a42e70a2a1a02ad8","unresolved":false,"context_lines":[{"line_number":1487,"context_line":""},{"line_number":1488,"context_line":"                    if (original_task_state in (task_states.DELETING,"},{"line_number":1489,"context_line":"                                                  task_states.SOFT_DELETING)"},{"line_number":1490,"context_line":"                        and instance.vm_state !\u003d vm_states.ERROR):"},{"line_number":1491,"context_line":"                        LOG.info(_(\u0027Instance is already in deleting state, \u0027"},{"line_number":1492,"context_line":"                                   \u0027ignoring this request\u0027), instance\u003dinstance)"},{"line_number":1493,"context_line":"                        if reservations:"}],"source_content_type":"text/x-python","patch_set":3,"id":"1ae5cdf2_fbbe0264","line":1490,"updated":"2014-06-13 00:39:07.000000000","message":"So this change says \u0027if its trying to delete and it hasn\u0027t reached ERROR, log and *ignore*\u0027, which exits early and thus prevents us putting a duplicate delete onto the bus. So this \u0027fixes\u0027 the problem by existing early if we haven\u0027t yet reached \u0027ERROR\u0027, and also allows ERROR to be reattempted.\n\nThe problem is that by doing this we now an unlimited number of attempts to be passed to the compute on the bus and they can all execute concurrently.\n\nThe task_state setting before was acting as a gatekeeper to prevent concurrent attempts to delete, and this is undoing that because nothing will change the overall state out of ERROR.\n\nI believe that Phils patch is the root cause here - it ends up violating the intent of task_states... e.g. what it should have been asked to do instead is to put into an ERROR(task_failed) state, which would signal that no user commands are permitted, but there are no open tasks on the compute nodes.... \n\nThis one currently does prevent concurrent attempts - and if we decide to allow attempts from the user to delete delete_failed, it would move the task_state back to DELETING/SOFT_DELETING.","commit_id":"3705629e3a2eaccf380978c1016610c49804a8fa"},{"author":{"_account_id":1849,"name":"Joe Gordon","email":"joe.gordon0@gmail.com","username":"jogo"},"change_message_id":"845c9d4731b9d1d08b56e0c6bef1f5935dbede85","unresolved":false,"context_lines":[{"line_number":1487,"context_line":""},{"line_number":1488,"context_line":"                    if (original_task_state in (task_states.DELETING,"},{"line_number":1489,"context_line":"                                                  task_states.SOFT_DELETING)"},{"line_number":1490,"context_line":"                        and instance.vm_state !\u003d vm_states.ERROR):"},{"line_number":1491,"context_line":"                        LOG.info(_(\u0027Instance is already in deleting state, \u0027"},{"line_number":1492,"context_line":"                                   \u0027ignoring this request\u0027), instance\u003dinstance)"},{"line_number":1493,"context_line":"                        if reservations:"}],"source_content_type":"text/x-python","patch_set":3,"id":"1ae5cdf2_f684595f","line":1490,"in_reply_to":"1ae5cdf2_fbbe0264","updated":"2014-06-13 00:57:43.000000000","message":"I agree with you that this is a sub-optimal solution, but I see this patch as an immediate fix while we can hash out what a better solution would be.\n\nThings like tasks will help with this, and I am hesitant to implement your proposal without further thought and planning (nova-spec?). What you are proposing is changing the API in subtle ways, and we have to be very careful about doing that.\n\nAs for the multiple deletes issue, if a cloud has enough instances in error,deleting state to make this a problem. Then the root issue is why there are so many failed deletes.\n\nAlso we don\u0027t universally enforce the notion that a instance can have one pending task right now.","commit_id":"3705629e3a2eaccf380978c1016610c49804a8fa"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"ad64a3bf7bcbe7053b6503dde5bad2dd91b9d834","unresolved":false,"context_lines":[{"line_number":1487,"context_line":""},{"line_number":1488,"context_line":"                    if (original_task_state in (task_states.DELETING,"},{"line_number":1489,"context_line":"                                                  task_states.SOFT_DELETING)"},{"line_number":1490,"context_line":"                        and instance.vm_state !\u003d vm_states.ERROR):"},{"line_number":1491,"context_line":"                        LOG.info(_(\u0027Instance is already in deleting state, \u0027"},{"line_number":1492,"context_line":"                                   \u0027ignoring this request\u0027), instance\u003dinstance)"},{"line_number":1493,"context_line":"                        if reservations:"}],"source_content_type":"text/x-python","patch_set":4,"id":"1ae5cdf2_ada352b0","line":1490,"updated":"2014-06-13 12:36:36.000000000","message":"Minor nit, but this indentation could end up being confusing since it lines up with the next line.  Perhaps indent one more level?","commit_id":"bb4202b0104a65f5bf04f1c469c4e3328e6b4b6a"},{"author":{"_account_id":1849,"name":"Joe Gordon","email":"joe.gordon0@gmail.com","username":"jogo"},"change_message_id":"4094ba1567f9ea6f94e6c95c5e6385f319263d0a","unresolved":false,"context_lines":[{"line_number":1487,"context_line":""},{"line_number":1488,"context_line":"                    if (original_task_state in (task_states.DELETING,"},{"line_number":1489,"context_line":"                                                  task_states.SOFT_DELETING)"},{"line_number":1490,"context_line":"                        and instance.vm_state !\u003d vm_states.ERROR):"},{"line_number":1491,"context_line":"                        LOG.info(_(\u0027Instance is already in deleting state, \u0027"},{"line_number":1492,"context_line":"                                   \u0027ignoring this request\u0027), instance\u003dinstance)"},{"line_number":1493,"context_line":"                        if reservations:"}],"source_content_type":"text/x-python","patch_set":4,"id":"1ae5cdf2_ed555550","line":1490,"in_reply_to":"1ae5cdf2_ada352b0","updated":"2014-06-13 15:28:25.000000000","message":"sigh, this is why we have hacking so we don\u0027t have to worry about things like this.\n\nIf I have to respin I\u0027ll be happy to fix this.","commit_id":"bb4202b0104a65f5bf04f1c469c4e3328e6b4b6a"}],"nova/tests/api/openstack/compute/test_servers.py":[{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"1f0e68d0e91b735b74f8daffce537e048932e260","unresolved":false,"context_lines":[{"line_number":1465,"context_line":"        req \u003d self._create_delete_request(FAKE_UUID)"},{"line_number":1466,"context_line":"        self.stubs.Set(db, \u0027instance_get_by_uuid\u0027,"},{"line_number":1467,"context_line":"            fakes.fake_instance_get(vm_state\u003dvm_states.ERROR,"},{"line_number":1468,"context_line":"                                    task_state\u003dtask_states.DELETING))"},{"line_number":1469,"context_line":""},{"line_number":1470,"context_line":"        self.controller.delete(req, FAKE_UUID)"},{"line_number":1471,"context_line":"        # Delete should be allowed because the is in an error state."}],"source_content_type":"text/x-python","patch_set":4,"id":"1ae5cdf2_5e227ab9","line":1468,"updated":"2014-06-13 09:54:41.000000000","message":"maybe mock can be used here ..","commit_id":"bb4202b0104a65f5bf04f1c469c4e3328e6b4b6a"},{"author":{"_account_id":1849,"name":"Joe Gordon","email":"joe.gordon0@gmail.com","username":"jogo"},"change_message_id":"4094ba1567f9ea6f94e6c95c5e6385f319263d0a","unresolved":false,"context_lines":[{"line_number":1465,"context_line":"        req \u003d self._create_delete_request(FAKE_UUID)"},{"line_number":1466,"context_line":"        self.stubs.Set(db, \u0027instance_get_by_uuid\u0027,"},{"line_number":1467,"context_line":"            fakes.fake_instance_get(vm_state\u003dvm_states.ERROR,"},{"line_number":1468,"context_line":"                                    task_state\u003dtask_states.DELETING))"},{"line_number":1469,"context_line":""},{"line_number":1470,"context_line":"        self.controller.delete(req, FAKE_UUID)"},{"line_number":1471,"context_line":"        # Delete should be allowed because the is in an error state."}],"source_content_type":"text/x-python","patch_set":4,"id":"1ae5cdf2_0dd8c1ed","line":1468,"in_reply_to":"1ae5cdf2_2da582a1","updated":"2014-06-13 15:28:25.000000000","message":"sure, all future work.","commit_id":"bb4202b0104a65f5bf04f1c469c4e3328e6b4b6a"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"ad64a3bf7bcbe7053b6503dde5bad2dd91b9d834","unresolved":false,"context_lines":[{"line_number":1465,"context_line":"        req \u003d self._create_delete_request(FAKE_UUID)"},{"line_number":1466,"context_line":"        self.stubs.Set(db, \u0027instance_get_by_uuid\u0027,"},{"line_number":1467,"context_line":"            fakes.fake_instance_get(vm_state\u003dvm_states.ERROR,"},{"line_number":1468,"context_line":"                                    task_state\u003dtask_states.DELETING))"},{"line_number":1469,"context_line":""},{"line_number":1470,"context_line":"        self.controller.delete(req, FAKE_UUID)"},{"line_number":1471,"context_line":"        # Delete should be allowed because the is in an error state."}],"source_content_type":"text/x-python","patch_set":4,"id":"1ae5cdf2_2da582a1","line":1468,"in_reply_to":"1ae5cdf2_5e227ab9","updated":"2014-06-13 12:36:36.000000000","message":"It would be nice to write new tests with mock, but this keeps all of the delete tests consistent and they can be rewritten together at a later time.\n\nBut since there is a lot of overlap between the tests you could factor out a helper method for them.","commit_id":"bb4202b0104a65f5bf04f1c469c4e3328e6b4b6a"}]}
