)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"5ad80785636940aa777fed703a200cf78a9f687a","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add find host logic on rebuild_instance."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"In the event of a unrecoverable hardware failure, support needs to"},{"line_number":10,"context_line":"relocate an instance to another compute so it can be rebuilt."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"  [*] Add logic required to support rebuild without host."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":11,"id":"AAAAVX%2F%2FpSg%3D","line":9,"updated":"2014-03-02 03:41:19.000000000","message":"a\u003d\u003d\u003ean","commit_id":"3160656b2b6c20ca752a9c4396ed8fd56fcfed8b"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"14d8e348286790588198389166a6163eb0d747f7","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add find host logic on rebuild_instance."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"In the event of a unrecoverable hardware failure, support needs to"},{"line_number":10,"context_line":"relocate an instance to another compute so it can be rebuilt."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"  [*] Add logic required to support rebuild without host."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":11,"id":"AAAAVX%2F%2FoSM%3D","line":9,"in_reply_to":"AAAAVX%2F%2FpSg%3D","updated":"2014-03-02 12:21:07.000000000","message":"Done","commit_id":"3160656b2b6c20ca752a9c4396ed8fd56fcfed8b"}],"nova/api/openstack/compute/servers.py":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"1c730a89e6cb40f7de83978319169377ba52ec3c","unresolved":false,"context_lines":[{"line_number":1259,"context_line":"            body \u003d body[\u0027rebuild\u0027]"},{"line_number":1260,"context_line":"        except (KeyError, TypeError):"},{"line_number":1261,"context_line":"            msg \u003d _(\u0027Invalid request body\u0027)"},{"line_number":1262,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg)"},{"line_number":1263,"context_line":""},{"line_number":1264,"context_line":"        try:"},{"line_number":1265,"context_line":"            image_href \u003d body[\"imageRef\"]"}],"source_content_type":"text/x-python","patch_set":1,"id":"AAAATn%2F%2FKLg%3D","side":"PARENT","line":1262,"updated":"2013-11-13 15:50:02.000000000","message":"Um, why was this removed?","commit_id":"0e5fff4db3ddd302861215056454b72ac2fe5605"},{"author":{"_account_id":7602,"name":"Claxton Correya","email":"claxton@gmail.com","username":"claxton"},"change_message_id":"0a3150968eef63757ad008307f1387545564b031","unresolved":false,"context_lines":[{"line_number":1259,"context_line":"            body \u003d body[\u0027rebuild\u0027]"},{"line_number":1260,"context_line":"        except (KeyError, TypeError):"},{"line_number":1261,"context_line":"            msg \u003d _(\u0027Invalid request body\u0027)"},{"line_number":1262,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg)"},{"line_number":1263,"context_line":""},{"line_number":1264,"context_line":"        try:"},{"line_number":1265,"context_line":"            image_href \u003d body[\"imageRef\"]"}],"source_content_type":"text/x-python","patch_set":1,"id":"AAAATn%2F%2FIFY%3D","side":"PARENT","line":1262,"in_reply_to":"AAAATn%2F%2FIMs%3D","updated":"2013-11-14 04:43:09.000000000","message":"Fixing typos.\n\nAny method decorated with wsgi.action will need to have the said key, in this case \u0027rebuild\u0027, before it reaches the relevant code block. If not, a key error is raised when the wsgi.action code kicks in. So this feels like a redundant check.","commit_id":"0e5fff4db3ddd302861215056454b72ac2fe5605"},{"author":{"_account_id":7602,"name":"Claxton Correya","email":"claxton@gmail.com","username":"claxton"},"change_message_id":"dd0ad4dad8913a17db24684df5760db2abe7e6ff","unresolved":false,"context_lines":[{"line_number":1259,"context_line":"            body \u003d body[\u0027rebuild\u0027]"},{"line_number":1260,"context_line":"        except (KeyError, TypeError):"},{"line_number":1261,"context_line":"            msg \u003d _(\u0027Invalid request body\u0027)"},{"line_number":1262,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg)"},{"line_number":1263,"context_line":""},{"line_number":1264,"context_line":"        try:"},{"line_number":1265,"context_line":"            image_href \u003d body[\"imageRef\"]"}],"source_content_type":"text/x-python","patch_set":1,"id":"AAAATn%2F%2FIMs%3D","side":"PARENT","line":1262,"in_reply_to":"AAAATn%2F%2FKLg%3D","updated":"2013-11-14 04:08:05.000000000","message":"Any method decorated with the wsgi.action will need to the said key, in this case \u0027rebuild\u0027 before it reaches the current code block. If not a key error when the wsgi.action code kicks in. So this is a redundant check.","commit_id":"0e5fff4db3ddd302861215056454b72ac2fe5605"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"d43f48e7989bc65fc31d23da22aa8050d95b3498","unresolved":false,"context_lines":[{"line_number":1259,"context_line":"            body \u003d body[\u0027rebuild\u0027]"},{"line_number":1260,"context_line":"        except (KeyError, TypeError):"},{"line_number":1261,"context_line":"            msg \u003d _(\u0027Invalid request body\u0027)"},{"line_number":1262,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg)"},{"line_number":1263,"context_line":""},{"line_number":1264,"context_line":"        try:"},{"line_number":1265,"context_line":"            image_href \u003d body[\"imageRef\"]"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2Bs1M%3D","side":"PARENT","line":1262,"updated":"2013-11-21 11:31:03.000000000","message":"This is important, why have you removed it?\n\nAlso, if you change v2, you also need to change the v3 API.\n\nI also can\u0027t see any unit tests.","commit_id":"b9cf2090daf21412f27a38309a19f91eeb94cd46"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"2d9cc8fec4a3a062e2b07e6e107912734592eb2c","unresolved":false,"context_lines":[{"line_number":1259,"context_line":"            body \u003d body[\u0027rebuild\u0027]"},{"line_number":1260,"context_line":"        except (KeyError, TypeError):"},{"line_number":1261,"context_line":"            msg \u003d _(\u0027Invalid request body\u0027)"},{"line_number":1262,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg)"},{"line_number":1263,"context_line":""},{"line_number":1264,"context_line":"        try:"},{"line_number":1265,"context_line":"            image_href \u003d body[\"imageRef\"]"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2BnSI%3D","side":"PARENT","line":1262,"in_reply_to":"AAAATn%2F%2Bo9c%3D","updated":"2013-11-22 14:04:52.000000000","message":"OK, if this is just a redundant check you have removed, this needs to be in separate change by itself, that has no dependencies with the other patches in this series, if possible.","commit_id":"b9cf2090daf21412f27a38309a19f91eeb94cd46"},{"author":{"_account_id":7602,"name":"Claxton Correya","email":"claxton@gmail.com","username":"claxton"},"change_message_id":"a0c7d09ab0681003db0783592a96b02881720e0f","unresolved":false,"context_lines":[{"line_number":1259,"context_line":"            body \u003d body[\u0027rebuild\u0027]"},{"line_number":1260,"context_line":"        except (KeyError, TypeError):"},{"line_number":1261,"context_line":"            msg \u003d _(\u0027Invalid request body\u0027)"},{"line_number":1262,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg)"},{"line_number":1263,"context_line":""},{"line_number":1264,"context_line":"        try:"},{"line_number":1265,"context_line":"            image_href \u003d body[\"imageRef\"]"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2Bo9c%3D","side":"PARENT","line":1262,"in_reply_to":"AAAATn%2F%2Bs1M%3D","updated":"2013-11-22 05:25:29.000000000","message":"Any method decorated with wsgi.action will need to have the said key, in this case \u0027rebuild\u0027, before it reaches the relevant code block. If not, a key error is raised when the wsgi.action code kicks in. So this feels like a redundant check.\n\nMy mistake. Shall make the changes for v3 api.","commit_id":"b9cf2090daf21412f27a38309a19f91eeb94cd46"}],"nova/compute/api.py":[{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"2d9cc8fec4a3a062e2b07e6e107912734592eb2c","unresolved":false,"context_lines":[{"line_number":2085,"context_line":""},{"line_number":2086,"context_line":"        self._record_action_start(context, instance, instance_actions.REBUILD)"},{"line_number":2087,"context_line":""},{"line_number":2088,"context_line":"        self.compute_task_api.rebuild_instance(context, instance\u003dinstance,"},{"line_number":2089,"context_line":"                new_pass\u003dadmin_password, injected_files\u003dfiles_to_inject,"},{"line_number":2090,"context_line":"                image_ref\u003dimage_href, orig_image_ref\u003dorig_image_ref,"},{"line_number":2091,"context_line":"                orig_sys_metadata\u003dorig_sys_metadata, bdms\u003dbdms)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2BnOQ%3D","line":2088,"updated":"2013-11-22 14:04:52.000000000","message":"This should have been done in the previous patch, IMHO","commit_id":"b68180fb39d2a1fb92bd75dfdf91d45b54e0babb"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"2d9cc8fec4a3a062e2b07e6e107912734592eb2c","unresolved":false,"context_lines":[{"line_number":2924,"context_line":""},{"line_number":2925,"context_line":"        self._record_action_start(context, instance, instance_actions.EVACUATE)"},{"line_number":2926,"context_line":""},{"line_number":2927,"context_line":"        return self.compute_task_api.rebuild_instance(context,"},{"line_number":2928,"context_line":"                                        instance\u003dinstance,"},{"line_number":2929,"context_line":"                                        new_pass\u003dadmin_password,"},{"line_number":2930,"context_line":"                                        injected_files\u003dNone,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2BnOI%3D","line":2927,"updated":"2013-11-22 14:04:52.000000000","message":"This should have been done in the previous patch, IMHO","commit_id":"b68180fb39d2a1fb92bd75dfdf91d45b54e0babb"}],"nova/conductor/api.py":[{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"d43f48e7989bc65fc31d23da22aa8050d95b3498","unresolved":false,"context_lines":[{"line_number":442,"context_line":"    def rebuild_instance(self, context, instance, new_pass,"},{"line_number":443,"context_line":"                         injected_files, image_ref, orig_image_ref,"},{"line_number":444,"context_line":"                         orig_sys_metadata, bdms,"},{"line_number":445,"context_line":"                         recreate\u003dFalse, on_shared_storage\u003dFalse, host\u003dNone):"},{"line_number":446,"context_line":"        self.conductor_compute_rpcapi.rebuild_instance(context\u003dcontext,"},{"line_number":447,"context_line":"                instance\u003dinstance,"},{"line_number":448,"context_line":"                new_pass\u003dnew_pass,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2Bs0E%3D","line":445,"updated":"2013-11-21 11:31:03.000000000","message":"I think all these should be included in your previous change, otherwise you need to look at bumping the version of things here.","commit_id":"b68180fb39d2a1fb92bd75dfdf91d45b54e0babb"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"2d9cc8fec4a3a062e2b07e6e107912734592eb2c","unresolved":false,"context_lines":[{"line_number":442,"context_line":"    def rebuild_instance(self, context, instance, new_pass,"},{"line_number":443,"context_line":"                         injected_files, image_ref, orig_image_ref,"},{"line_number":444,"context_line":"                         orig_sys_metadata, bdms,"},{"line_number":445,"context_line":"                         recreate\u003dFalse, on_shared_storage\u003dFalse, host\u003dNone):"},{"line_number":446,"context_line":"        self.conductor_compute_rpcapi.rebuild_instance(context\u003dcontext,"},{"line_number":447,"context_line":"                instance\u003dinstance,"},{"line_number":448,"context_line":"                new_pass\u003dnew_pass,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2BnRo%3D","line":445,"in_reply_to":"AAAATn%2F%2Bo9I%3D","updated":"2013-11-22 14:04:52.000000000","message":"OK, I think we need to get this split sorted out a bit better.","commit_id":"b68180fb39d2a1fb92bd75dfdf91d45b54e0babb"},{"author":{"_account_id":7602,"name":"Claxton Correya","email":"claxton@gmail.com","username":"claxton"},"change_message_id":"a0c7d09ab0681003db0783592a96b02881720e0f","unresolved":false,"context_lines":[{"line_number":442,"context_line":"    def rebuild_instance(self, context, instance, new_pass,"},{"line_number":443,"context_line":"                         injected_files, image_ref, orig_image_ref,"},{"line_number":444,"context_line":"                         orig_sys_metadata, bdms,"},{"line_number":445,"context_line":"                         recreate\u003dFalse, on_shared_storage\u003dFalse, host\u003dNone):"},{"line_number":446,"context_line":"        self.conductor_compute_rpcapi.rebuild_instance(context\u003dcontext,"},{"line_number":447,"context_line":"                instance\u003dinstance,"},{"line_number":448,"context_line":"                new_pass\u003dnew_pass,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2Bo9I%3D","line":445,"in_reply_to":"AAAATn%2F%2Bs0E%3D","updated":"2013-11-22 05:25:29.000000000","message":"Initially had pushed a single commit for the whole change. Got a review comment stating that its a big change and split it. I\u0027m happy to merge them as long as its approved.","commit_id":"b68180fb39d2a1fb92bd75dfdf91d45b54e0babb"}],"nova/conductor/manager.py":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"1c730a89e6cb40f7de83978319169377ba52ec3c","unresolved":false,"context_lines":[{"line_number":836,"context_line":"    def rebuild_instance(self, context, instance, new_pass,"},{"line_number":837,"context_line":"                         injected_files, image_ref, orig_image_ref,"},{"line_number":838,"context_line":"                         orig_sys_metadata, bdms,"},{"line_number":839,"context_line":"                         recreate\u003dFalse, on_shared_storage\u003dFalse, host\u003dNone):"},{"line_number":840,"context_line":"        self.compute_rpcapi.rebuild_instance(ctxt\u003dcontext,"},{"line_number":841,"context_line":"            instance\u003dinstance, new_pass\u003dnew_pass,"},{"line_number":842,"context_line":"            injected_files\u003dinjected_files, image_ref\u003dimage_ref,"}],"source_content_type":"text/x-python","patch_set":1,"id":"AAAATn%2F%2FKMg%3D","line":839,"updated":"2013-11-13 15:50:02.000000000","message":"This needs a version bump.","commit_id":"88d8ac3244844116d1870487f5c1c1e9f19dea95"},{"author":{"_account_id":7602,"name":"Claxton Correya","email":"claxton@gmail.com","username":"claxton"},"change_message_id":"dd0ad4dad8913a17db24684df5760db2abe7e6ff","unresolved":false,"context_lines":[{"line_number":836,"context_line":"    def rebuild_instance(self, context, instance, new_pass,"},{"line_number":837,"context_line":"                         injected_files, image_ref, orig_image_ref,"},{"line_number":838,"context_line":"                         orig_sys_metadata, bdms,"},{"line_number":839,"context_line":"                         recreate\u003dFalse, on_shared_storage\u003dFalse, host\u003dNone):"},{"line_number":840,"context_line":"        self.compute_rpcapi.rebuild_instance(ctxt\u003dcontext,"},{"line_number":841,"context_line":"            instance\u003dinstance, new_pass\u003dnew_pass,"},{"line_number":842,"context_line":"            injected_files\u003dinjected_files, image_ref\u003dimage_ref,"}],"source_content_type":"text/x-python","patch_set":1,"id":"AAAATn%2F%2FIJM%3D","line":839,"in_reply_to":"AAAATn%2F%2FKMg%3D","updated":"2013-11-14 04:08:05.000000000","message":"Done","commit_id":"88d8ac3244844116d1870487f5c1c1e9f19dea95"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"d43f48e7989bc65fc31d23da22aa8050d95b3498","unresolved":false,"context_lines":[{"line_number":838,"context_line":"    def rebuild_instance(self, context, instance, new_pass,"},{"line_number":839,"context_line":"                         injected_files, image_ref, orig_image_ref,"},{"line_number":840,"context_line":"                         orig_sys_metadata, bdms,"},{"line_number":841,"context_line":"                         recreate\u003dFalse, on_shared_storage\u003dFalse, host\u003dNone):"},{"line_number":842,"context_line":"        self.compute_rpcapi.rebuild_instance(ctxt\u003dcontext,"},{"line_number":843,"context_line":"            instance\u003dinstance, new_pass\u003dnew_pass,"},{"line_number":844,"context_line":"            injected_files\u003dinjected_files, image_ref\u003dimage_ref,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2Bsz8%3D","line":841,"updated":"2013-11-21 11:31:03.000000000","message":"Why not put all this in your original change where you add rebuild_instance?","commit_id":"b68180fb39d2a1fb92bd75dfdf91d45b54e0babb"},{"author":{"_account_id":7602,"name":"Claxton Correya","email":"claxton@gmail.com","username":"claxton"},"change_message_id":"a0c7d09ab0681003db0783592a96b02881720e0f","unresolved":false,"context_lines":[{"line_number":838,"context_line":"    def rebuild_instance(self, context, instance, new_pass,"},{"line_number":839,"context_line":"                         injected_files, image_ref, orig_image_ref,"},{"line_number":840,"context_line":"                         orig_sys_metadata, bdms,"},{"line_number":841,"context_line":"                         recreate\u003dFalse, on_shared_storage\u003dFalse, host\u003dNone):"},{"line_number":842,"context_line":"        self.compute_rpcapi.rebuild_instance(ctxt\u003dcontext,"},{"line_number":843,"context_line":"            instance\u003dinstance, new_pass\u003dnew_pass,"},{"line_number":844,"context_line":"            injected_files\u003dinjected_files, image_ref\u003dimage_ref,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2Bo80%3D","line":841,"in_reply_to":"AAAATn%2F%2Bsz8%3D","updated":"2013-11-22 05:25:29.000000000","message":"As stated earlier had to split the commit. Rebuild instance by itself does not need explicitly need a host. So refrained from adding the extra parameters which are needed for the evacuate workflow. Merging the commits should help.","commit_id":"b68180fb39d2a1fb92bd75dfdf91d45b54e0babb"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"b8f45c18efcdb4201a72726924ae613e2b112532","unresolved":false,"context_lines":[{"line_number":858,"context_line":"                hosts \u003d self.scheduler_rpcapi.select_destinations(context,"},{"line_number":859,"context_line":"                                                            request_spec,"},{"line_number":860,"context_line":"                                                            filter_properties)"},{"line_number":861,"context_line":"            except exception.NoValidHost as ex:"},{"line_number":862,"context_line":"                scheduler_utils.set_vm_state_and_notify(context,"},{"line_number":863,"context_line":"                        \u0027compute_task\u0027, \u0027rebuild_server\u0027,"},{"line_number":864,"context_line":"                        dict(vm_state\u003dvm_states.ERROR,"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUX%2F%2FXNk%3D","line":861,"updated":"2014-02-13 18:05:29.000000000","message":"If there\u0027s a novalidhost the state will be ERROR,\nbut if the rpc message time out (scheduler down), it\u0027s not clear to us if the vm should be in ERROR_STATE also or switch back to original STATE ( at this point nothing from the instance has changed. )\n\nThe problem with going back to the original state is that an automatic process ( or not) has to remember if the instance even if ACTIVE again has been moved from the original host.\n\nif we don\u0027t do nothing, then the state will be rebuild_scheduling for ever.\n\nShall we just do something like\n\n except Exception as ex:\n            with excutils.save_and_reraise_exception():\n                   ... set error state ...\n\n?","commit_id":"bff54ba51df88ced6232fc1e652c954dfcb5e888"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"56e8692d25b9f3973539c6737ae73a683084961c","unresolved":false,"context_lines":[{"line_number":867,"context_line":"                                                            request_spec,"},{"line_number":868,"context_line":"                                                            filter_properties)"},{"line_number":869,"context_line":"            except exception.NoValidHost as ex:"},{"line_number":870,"context_line":"                scheduler_utils.set_vm_state_and_notify(context,"},{"line_number":871,"context_line":"                        \u0027compute_task\u0027, \u0027rebuild_server\u0027,"},{"line_number":872,"context_line":"                        dict(vm_state\u003dvm_states.ERROR,"},{"line_number":873,"context_line":"                             task_state\u003dNone),"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAUX%2F%2B01Y%3D","line":870,"updated":"2014-02-18 19:22:15.000000000","message":"If there\u0027s a novalidhost the state will be ERROR, but if the rpc message time out (scheduler down), it\u0027s not clear to us if the vm should be in ERROR_STATE also or switch back to original STATE ( at this point nothing from the instance has changed. )\nThe problem with going back to the original state is that an automatic process ( or not) has to remember if the instance even if ACTIVE again has been moved from the original host.\nif we don\u0027t do nothing, then the state will be rebuild_scheduling for ever.\nShall we just do something like\n except Exception as ex:\n            with excutils.save_and_reraise_exception():\n                   ... set error state ...\n?","commit_id":"f62d0cdd9dbee719e7ec0a484a3b3a6dee78aabd"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"431c5b8076977af3b7489cce86bd06cfcc7bf472","unresolved":false,"context_lines":[{"line_number":872,"context_line":"                                                            request_spec,"},{"line_number":873,"context_line":"                                                            filter_properties)"},{"line_number":874,"context_line":"            except exception.NoValidHost as ex:"},{"line_number":875,"context_line":"                scheduler_utils.set_vm_state_and_notify(context,"},{"line_number":876,"context_line":"                        \u0027compute_task\u0027, \u0027rebuild_server\u0027,"},{"line_number":877,"context_line":"                        dict(vm_state\u003dvm_states.ERROR,"},{"line_number":878,"context_line":"                             task_state\u003dNone),"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAVX%2F%2F5ec%3D","line":875,"updated":"2014-02-27 14:27:15.000000000","message":"You need to record information in the instance_action here, this is a new exit point that the decorator in compute manager will not catch.\n\nI am not sure you want the VM to go to ERROR, since we have not really done anything destructive to the server at this point.","commit_id":"72b3d28cc77993457f8889d71e9cea6ad6420cb2"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"c6a8c9c8d2cc06e5fbeb2de5c5fca5302386e556","unresolved":false,"context_lines":[{"line_number":872,"context_line":"                                                            request_spec,"},{"line_number":873,"context_line":"                                                            filter_properties)"},{"line_number":874,"context_line":"            except exception.NoValidHost as ex:"},{"line_number":875,"context_line":"                scheduler_utils.set_vm_state_and_notify(context,"},{"line_number":876,"context_line":"                        \u0027compute_task\u0027, \u0027rebuild_server\u0027,"},{"line_number":877,"context_line":"                        dict(vm_state\u003dvm_states.ERROR,"},{"line_number":878,"context_line":"                             task_state\u003dNone),"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAVX%2F%2F2ZU%3D","line":875,"in_reply_to":"AAAAVX%2F%2F44c%3D","updated":"2014-02-27 20:52:36.000000000","message":"Will add EventReport and reraise","commit_id":"72b3d28cc77993457f8889d71e9cea6ad6420cb2"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"98ffe3746d1502b0c930fb6ea3f642fce56100d9","unresolved":false,"context_lines":[{"line_number":872,"context_line":"                                                            request_spec,"},{"line_number":873,"context_line":"                                                            filter_properties)"},{"line_number":874,"context_line":"            except exception.NoValidHost as ex:"},{"line_number":875,"context_line":"                scheduler_utils.set_vm_state_and_notify(context,"},{"line_number":876,"context_line":"                        \u0027compute_task\u0027, \u0027rebuild_server\u0027,"},{"line_number":877,"context_line":"                        dict(vm_state\u003dvm_states.ERROR,"},{"line_number":878,"context_line":"                             task_state\u003dNone),"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAVX%2F%2F44c%3D","line":875,"in_reply_to":"AAAAVX%2F%2F5ec%3D","updated":"2014-02-27 15:39:17.000000000","message":"You mean adding something like compute/api.py evacuate?\nself._record_action_start(context, instance, instance_actions.EVACUATE) \noutside of the exception? I\n\nCouldn\u0027t find an example of doing this on errors. It\u0027s not clear to me if scheduler_utils.set_vm_state_and_notify should be kept and add the instance record.\n\nRegarding the state i agree, but the user will need to check if the host changed to determine error/success.","commit_id":"72b3d28cc77993457f8889d71e9cea6ad6420cb2"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"431c5b8076977af3b7489cce86bd06cfcc7bf472","unresolved":false,"context_lines":[{"line_number":881,"context_line":"                            instance\u003dinstance)"},{"line_number":882,"context_line":"                return"},{"line_number":883,"context_line":"            else:"},{"line_number":884,"context_line":"                host \u003d hosts.pop(0)[\u0027host\u0027]"},{"line_number":885,"context_line":""},{"line_number":886,"context_line":"        self.compute_rpcapi.rebuild_instance(context,"},{"line_number":887,"context_line":"                    instance\u003dinstance,"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAVX%2F%2F6tE%3D","line":884,"updated":"2014-02-27 14:27:15.000000000","message":"I worry about adding scheduler retries here.","commit_id":"72b3d28cc77993457f8889d71e9cea6ad6420cb2"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"79b6de6181613ebb89caa364ecd89d2c6131ba50","unresolved":false,"context_lines":[{"line_number":881,"context_line":"                            instance\u003dinstance)"},{"line_number":882,"context_line":"                return"},{"line_number":883,"context_line":"            else:"},{"line_number":884,"context_line":"                host \u003d hosts.pop(0)[\u0027host\u0027]"},{"line_number":885,"context_line":""},{"line_number":886,"context_line":"        self.compute_rpcapi.rebuild_instance(context,"},{"line_number":887,"context_line":"                    instance\u003dinstance,"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAVX%2F%2F3HM%3D","line":884,"in_reply_to":"AAAAVX%2F%2F4vc%3D","updated":"2014-02-27 18:51:49.000000000","message":"Because bolting on retries takes a bit of work with the current code flow, and this can only be triggered by admins who know what they\u0027re doing, I would leave retries to the admins for now.","commit_id":"72b3d28cc77993457f8889d71e9cea6ad6420cb2"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"98ffe3746d1502b0c930fb6ea3f642fce56100d9","unresolved":false,"context_lines":[{"line_number":881,"context_line":"                            instance\u003dinstance)"},{"line_number":882,"context_line":"                return"},{"line_number":883,"context_line":"            else:"},{"line_number":884,"context_line":"                host \u003d hosts.pop(0)[\u0027host\u0027]"},{"line_number":885,"context_line":""},{"line_number":886,"context_line":"        self.compute_rpcapi.rebuild_instance(context,"},{"line_number":887,"context_line":"                    instance\u003dinstance,"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAVX%2F%2F4vc%3D","line":884,"in_reply_to":"AAAAVX%2F%2F6tE%3D","updated":"2014-02-27 15:39:17.000000000","message":"i tried to follow _cold_migrate(). I can  remove the else and move it up, but don\u0027t know if that enough.","commit_id":"72b3d28cc77993457f8889d71e9cea6ad6420cb2"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"5ad80785636940aa777fed703a200cf78a9f687a","unresolved":false,"context_lines":[{"line_number":862,"context_line":"                         preserve_ephemeral\u003dFalse, host\u003dNone,"},{"line_number":863,"context_line":"                         pick_host_with_scheduler\u003dFalse):"},{"line_number":864,"context_line":"        if pick_host_with_scheduler:"},{"line_number":865,"context_line":"            filter_properties \u003d {\u0027ignore_hosts\u0027: [instance[\u0027host\u0027]]}"},{"line_number":866,"context_line":"            request_spec \u003d scheduler_utils.build_request_spec(context,"},{"line_number":867,"context_line":"                                                            image_ref,"},{"line_number":868,"context_line":"                                                            [instance])"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAVX%2F%2FpSc%3D","line":865,"updated":"2014-03-02 03:41:19.000000000","message":"Perhaps we need to store scheduler hints somewhere for a VM, as here \"ignore_hosts\" will overwrite its original deploy decision. I\u0027m now trying handle this in https://review.openstack.org/#/c/62408/ , this was now deferred to Juno","commit_id":"3160656b2b6c20ca752a9c4396ed8fd56fcfed8b"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"14d8e348286790588198389166a6163eb0d747f7","unresolved":false,"context_lines":[{"line_number":862,"context_line":"                         preserve_ephemeral\u003dFalse, host\u003dNone,"},{"line_number":863,"context_line":"                         pick_host_with_scheduler\u003dFalse):"},{"line_number":864,"context_line":"        if pick_host_with_scheduler:"},{"line_number":865,"context_line":"            filter_properties \u003d {\u0027ignore_hosts\u0027: [instance[\u0027host\u0027]]}"},{"line_number":866,"context_line":"            request_spec \u003d scheduler_utils.build_request_spec(context,"},{"line_number":867,"context_line":"                                                            image_ref,"},{"line_number":868,"context_line":"                                                            [instance])"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAVX%2F%2FoSc%3D","line":865,"in_reply_to":"AAAAVX%2F%2FpSc%3D","updated":"2014-03-02 12:21:07.000000000","message":"Sure. Will happy to add that when available.\nThe reason of filtering the same host is that when pick_host_with_scheduler is set is because evacuate was called, so it make no sense to rebuild on a compute node that is down.\n\nBut i agree that scheduler hints should be retrieved someway to use them on rebuild.","commit_id":"3160656b2b6c20ca752a9c4396ed8fd56fcfed8b"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"5ad80785636940aa777fed703a200cf78a9f687a","unresolved":false,"context_lines":[{"line_number":878,"context_line":"                    vm_state \u003d instance[\u0027vm_state\u0027]"},{"line_number":879,"context_line":"                    self._set_vm_state_and_notify(context, \u0027rebuild_server\u0027,"},{"line_number":880,"context_line":"                        dict(vm_state\u003dinstance[\u0027vm_state\u0027],"},{"line_number":881,"context_line":"                             task_state\u003dNone), ex, request_spec)"},{"line_number":882,"context_line":"            else:"},{"line_number":883,"context_line":"                host \u003d hosts.pop(0)[\u0027host\u0027]"},{"line_number":884,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAVX%2F%2FpSY%3D","line":881,"updated":"2014-03-02 03:41:19.000000000","message":"return here?","commit_id":"3160656b2b6c20ca752a9c4396ed8fd56fcfed8b"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"7ec174c7a38c3b5ea340f6f56ceaf20c8d61eea8","unresolved":false,"context_lines":[{"line_number":878,"context_line":"                    vm_state \u003d instance[\u0027vm_state\u0027]"},{"line_number":879,"context_line":"                    self._set_vm_state_and_notify(context, \u0027rebuild_server\u0027,"},{"line_number":880,"context_line":"                        dict(vm_state\u003dinstance[\u0027vm_state\u0027],"},{"line_number":881,"context_line":"                             task_state\u003dNone), ex, request_spec)"},{"line_number":882,"context_line":"            else:"},{"line_number":883,"context_line":"                host \u003d hosts.pop(0)[\u0027host\u0027]"},{"line_number":884,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAVX%2F%2FoQ4%3D","line":881,"in_reply_to":"AAAAVX%2F%2FoSs%3D","updated":"2014-03-02 12:33:51.000000000","message":"Yes, you are right. Thanks.","commit_id":"3160656b2b6c20ca752a9c4396ed8fd56fcfed8b"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"14d8e348286790588198389166a6163eb0d747f7","unresolved":false,"context_lines":[{"line_number":878,"context_line":"                    vm_state \u003d instance[\u0027vm_state\u0027]"},{"line_number":879,"context_line":"                    self._set_vm_state_and_notify(context, \u0027rebuild_server\u0027,"},{"line_number":880,"context_line":"                        dict(vm_state\u003dinstance[\u0027vm_state\u0027],"},{"line_number":881,"context_line":"                             task_state\u003dNone), ex, request_spec)"},{"line_number":882,"context_line":"            else:"},{"line_number":883,"context_line":"                host \u003d hosts.pop(0)[\u0027host\u0027]"},{"line_number":884,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAVX%2F%2FoSs%3D","line":881,"in_reply_to":"AAAAVX%2F%2FpSY%3D","updated":"2014-03-02 12:21:07.000000000","message":"I will add ti make it clear. But i think that the close of executils.save_and_reraise_exceptions will raise the exception again?","commit_id":"3160656b2b6c20ca752a9c4396ed8fd56fcfed8b"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"5ec0f2f519be37cbb87b7a3d1a45eea73f8a4711","unresolved":false,"context_lines":[{"line_number":877,"context_line":"                with excutils.save_and_reraise_exception():"},{"line_number":878,"context_line":"                    vm_state \u003d instance[\u0027vm_state\u0027]"},{"line_number":879,"context_line":"                    self._set_vm_state_and_notify(context, \u0027rebuild_server\u0027,"},{"line_number":880,"context_line":"                        dict(vm_state\u003dinstance[\u0027vm_state\u0027],"},{"line_number":881,"context_line":"                             task_state\u003dNone), ex, request_spec)"},{"line_number":882,"context_line":"                return"},{"line_number":883,"context_line":"            else:"}],"source_content_type":"text/x-python","patch_set":13,"id":"AAAAVX%2F%2Fn9c%3D","line":880,"updated":"2014-03-02 16:38:44.000000000","message":"please use {} instead of dict.\nIt is meant to be more efficient (http://doughellmann.com/2012/11/the-performance-impact-of-using-dict-instead-of-in-cpython-2-7-2.html)","commit_id":"86dcc115c30db8bc2ffe440cc92fb3152fb8581b"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"d33291bfce83bc3f17b9404fd4d8371bd9c1c9b5","unresolved":false,"context_lines":[{"line_number":877,"context_line":"                with excutils.save_and_reraise_exception():"},{"line_number":878,"context_line":"                    vm_state \u003d instance[\u0027vm_state\u0027]"},{"line_number":879,"context_line":"                    self._set_vm_state_and_notify(context, \u0027rebuild_server\u0027,"},{"line_number":880,"context_line":"                        dict(vm_state\u003dinstance[\u0027vm_state\u0027],"},{"line_number":881,"context_line":"                             task_state\u003dNone), ex, request_spec)"},{"line_number":882,"context_line":"                return"},{"line_number":883,"context_line":"            else:"}],"source_content_type":"text/x-python","patch_set":13,"id":"AAAAVn%2F%2F%2FeY%3D","line":880,"in_reply_to":"AAAAVX%2F%2Fn9c%3D","updated":"2014-03-02 21:26:30.000000000","message":"Done","commit_id":"86dcc115c30db8bc2ffe440cc92fb3152fb8581b"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"5ec0f2f519be37cbb87b7a3d1a45eea73f8a4711","unresolved":false,"context_lines":[{"line_number":878,"context_line":"                    vm_state \u003d instance[\u0027vm_state\u0027]"},{"line_number":879,"context_line":"                    self._set_vm_state_and_notify(context, \u0027rebuild_server\u0027,"},{"line_number":880,"context_line":"                        dict(vm_state\u003dinstance[\u0027vm_state\u0027],"},{"line_number":881,"context_line":"                             task_state\u003dNone), ex, request_spec)"},{"line_number":882,"context_line":"                return"},{"line_number":883,"context_line":"            else:"},{"line_number":884,"context_line":"                host \u003d hosts.pop(0)[\u0027host\u0027]"}],"source_content_type":"text/x-python","patch_set":13,"id":"AAAAVX%2F%2Fn9Y%3D","line":881,"updated":"2014-03-02 16:38:44.000000000","message":"maybe it is worth logging here","commit_id":"86dcc115c30db8bc2ffe440cc92fb3152fb8581b"},{"author":{"_account_id":9275,"name":"Leandro Ignacio Costantino","email":"leandro.i.costantino@intel.com","username":"lcostantino"},"change_message_id":"d33291bfce83bc3f17b9404fd4d8371bd9c1c9b5","unresolved":false,"context_lines":[{"line_number":878,"context_line":"                    vm_state \u003d instance[\u0027vm_state\u0027]"},{"line_number":879,"context_line":"                    self._set_vm_state_and_notify(context, \u0027rebuild_server\u0027,"},{"line_number":880,"context_line":"                        dict(vm_state\u003dinstance[\u0027vm_state\u0027],"},{"line_number":881,"context_line":"                             task_state\u003dNone), ex, request_spec)"},{"line_number":882,"context_line":"                return"},{"line_number":883,"context_line":"            else:"},{"line_number":884,"context_line":"                host \u003d hosts.pop(0)[\u0027host\u0027]"}],"source_content_type":"text/x-python","patch_set":13,"id":"AAAAVn%2F%2F%2Fec%3D","line":881,"in_reply_to":"AAAAVX%2F%2Fn9Y%3D","updated":"2014-03-02 21:26:30.000000000","message":"Done","commit_id":"86dcc115c30db8bc2ffe440cc92fb3152fb8581b"}],"nova/conductor/rpcapi.py":[{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"d43f48e7989bc65fc31d23da22aa8050d95b3498","unresolved":false,"context_lines":[{"line_number":549,"context_line":"                   image_ref\u003dimage_ref,"},{"line_number":550,"context_line":"                   orig_image_ref\u003dorig_image_ref,"},{"line_number":551,"context_line":"                   orig_sys_metadata\u003dorig_sys_metadata,"},{"line_number":552,"context_line":"                   bdms\u003dbdms_p, recreate\u003drecreate,"},{"line_number":553,"context_line":"                   on_shared_storage\u003don_shared_storage, host\u003dhost)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2BszQ%3D","line":552,"updated":"2013-11-21 11:31:03.000000000","message":"again, push this on your older change.","commit_id":"b68180fb39d2a1fb92bd75dfdf91d45b54e0babb"},{"author":{"_account_id":7602,"name":"Claxton Correya","email":"claxton@gmail.com","username":"claxton"},"change_message_id":"a0c7d09ab0681003db0783592a96b02881720e0f","unresolved":false,"context_lines":[{"line_number":549,"context_line":"                   image_ref\u003dimage_ref,"},{"line_number":550,"context_line":"                   orig_image_ref\u003dorig_image_ref,"},{"line_number":551,"context_line":"                   orig_sys_metadata\u003dorig_sys_metadata,"},{"line_number":552,"context_line":"                   bdms\u003dbdms_p, recreate\u003drecreate,"},{"line_number":553,"context_line":"                   on_shared_storage\u003don_shared_storage, host\u003dhost)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATn%2F%2Bo8s%3D","line":552,"in_reply_to":"AAAATn%2F%2BszQ%3D","updated":"2013-11-22 05:25:29.000000000","message":"Same as previous reply.","commit_id":"b68180fb39d2a1fb92bd75dfdf91d45b54e0babb"}]}
