)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"56b4cbd4150bc891fdf5910c95c9fc05d25ee7c0","unresolved":false,"context_lines":[{"line_number":5,"context_line":"CommitDate: 2016-03-09 00:54:22 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"modify code for resize failure can rollback to exact vm_state"},{"line_number":8,"context_line":"Closes-Bug: #1551703"},{"line_number":9,"context_line":""},{"line_number":10,"context_line":"Change-Id: Ib0557ef7de88fbef90353b0de3e68710cde4ce5c"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"5aef4532_ed78c3c6","line":8,"updated":"2016-03-09 02:22:47.000000000","message":"It would better to say something about what you changed in the patch","commit_id":"3377c69f59ec0a12eb1d8600ae0ffbb14fddaeb7"},{"author":{"_account_id":17898,"name":"Jinquan Ni","email":"ni.jinquan@zte.com.cn","username":"jinquanni"},"change_message_id":"ad1f5be8087d84a3ead4a624afd5fd2ddba105d7","unresolved":false,"context_lines":[{"line_number":5,"context_line":"CommitDate: 2016-03-09 00:54:22 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"modify code for resize failure can rollback to exact vm_state"},{"line_number":8,"context_line":"Closes-Bug: #1551703"},{"line_number":9,"context_line":""},{"line_number":10,"context_line":"Change-Id: Ib0557ef7de88fbef90353b0de3e68710cde4ce5c"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"5aef4532_813f48d5","line":8,"in_reply_to":"5aef4532_ed78c3c6","updated":"2016-03-09 05:20:55.000000000","message":"Done","commit_id":"3377c69f59ec0a12eb1d8600ae0ffbb14fddaeb7"}],"nova/compute/manager.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"52d8d79b1f71bfdd8f39c8986ffc50bb87a4b6ce","unresolved":false,"context_lines":[{"line_number":3841,"context_line":"                                                  instance\u003dinstance)"},{"line_number":3842,"context_line":"        with self._error_out_instance_on_exception("},{"line_number":3843,"context_line":"                context, instance, quotas\u003dquotas,"},{"line_number":3844,"context_line":"                instance_state\u003dinstance.vm_state):"},{"line_number":3845,"context_line":"            # TODO(chaochin) Remove this until v5 RPC API"},{"line_number":3846,"context_line":"            # Code downstream may expect extra_specs to be populated since it"},{"line_number":3847,"context_line":"            # is receiving an object, so lookup the flavor to ensure this."}],"source_content_type":"text/x-python","patch_set":7,"id":"5aef4532_0edfa50d","line":3844,"range":{"start_line":3844,"start_character":16,"end_line":3844,"end_character":48},"updated":"2016-03-09 22:14:20.000000000","message":"There was another patch for this at one point, and I\u0027ll raise the same issue here.\n\nIf this instance is STOPPED when we start the resize, and it\u0027s started as part of the resize to confirm it, but something fails, then when we revert the vm_state, it could be running, but we\u0027re going to stay the vm_state is STOPPED, which is a problem.","commit_id":"054633ec0577b2cda06447401f920e573b5f4859"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"2ac743a4931c1fa57df384d06f19f5d6c2847567","unresolved":false,"context_lines":[{"line_number":3841,"context_line":"                                                  instance\u003dinstance)"},{"line_number":3842,"context_line":"        with self._error_out_instance_on_exception("},{"line_number":3843,"context_line":"                context, instance, quotas\u003dquotas,"},{"line_number":3844,"context_line":"                instance_state\u003dinstance.vm_state):"},{"line_number":3845,"context_line":"            # TODO(chaochin) Remove this until v5 RPC API"},{"line_number":3846,"context_line":"            # Code downstream may expect extra_specs to be populated since it"},{"line_number":3847,"context_line":"            # is receiving an object, so lookup the flavor to ensure this."}],"source_content_type":"text/x-python","patch_set":7,"id":"3afc51ec_c185eb59","line":3844,"range":{"start_line":3844,"start_character":16,"end_line":3844,"end_character":48},"in_reply_to":"3afc51ec_c6036872","updated":"2016-03-14 14:19:56.000000000","message":"@Matt, thanks for explain, I see now and agree with you. That will be better. And we probably need to think about a method can be used generically, not only in resize rollback.","commit_id":"054633ec0577b2cda06447401f920e573b5f4859"},{"author":{"_account_id":17898,"name":"Jinquan Ni","email":"ni.jinquan@zte.com.cn","username":"jinquanni"},"change_message_id":"1cf2d895ad0126357bec06dbb3b38722266f6609","unresolved":false,"context_lines":[{"line_number":3841,"context_line":"                                                  instance\u003dinstance)"},{"line_number":3842,"context_line":"        with self._error_out_instance_on_exception("},{"line_number":3843,"context_line":"                context, instance, quotas\u003dquotas,"},{"line_number":3844,"context_line":"                instance_state\u003dinstance.vm_state):"},{"line_number":3845,"context_line":"            # TODO(chaochin) Remove this until v5 RPC API"},{"line_number":3846,"context_line":"            # Code downstream may expect extra_specs to be populated since it"},{"line_number":3847,"context_line":"            # is receiving an object, so lookup the flavor to ensure this."}],"source_content_type":"text/x-python","patch_set":7,"id":"3afc51ec_c6036872","line":3844,"range":{"start_line":3844,"start_character":16,"end_line":3844,"end_character":48},"in_reply_to":"3afc51ec_f7dc771a","updated":"2016-03-13 03:51:23.000000000","message":"(1)During processing patch https://review.openstack.org/#/c/202379/, through communication with Zhenyu Zheng,\nwe know that driver (except xen driver)layer does not change the vm\u0027s power state before the InstanceRollBack exception been thrown during resize.\nFortunately now xen had done the driver\u0027s rollback before throws InstanceRollBack exception, and this also supports Alex Xu\u0027s point of view.\nSo, I think this is properly handling.\n\n(2)The present process flow, direct roll back to ACTIVE will not take into account the various power states.\n\n(3)It should not be more concerned by the resize if vm_state and power_state already inconsistent before resize, \nResize only need to roll back to the Pre-operational state.\n\nThese are my views, thank you for your suggestions(@Zhenyu Zheng, @Alex Xu, @Matt Riedemann), thank you!","commit_id":"054633ec0577b2cda06447401f920e573b5f4859"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"ab874d00f5046fe4c314554df8943643f798b4da","unresolved":false,"context_lines":[{"line_number":3841,"context_line":"                                                  instance\u003dinstance)"},{"line_number":3842,"context_line":"        with self._error_out_instance_on_exception("},{"line_number":3843,"context_line":"                context, instance, quotas\u003dquotas,"},{"line_number":3844,"context_line":"                instance_state\u003dinstance.vm_state):"},{"line_number":3845,"context_line":"            # TODO(chaochin) Remove this until v5 RPC API"},{"line_number":3846,"context_line":"            # Code downstream may expect extra_specs to be populated since it"},{"line_number":3847,"context_line":"            # is receiving an object, so lookup the flavor to ensure this."}],"source_content_type":"text/x-python","patch_set":7,"id":"5aef4532_ced93d24","line":3844,"range":{"start_line":3844,"start_character":16,"end_line":3844,"end_character":48},"in_reply_to":"5aef4532_0edfa50d","updated":"2016-03-09 22:14:49.000000000","message":"Zhenyu already pointed this out:\n\nhttps://review.openstack.org/#/c/202379/","commit_id":"054633ec0577b2cda06447401f920e573b5f4859"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"3fe3074883ba1cd77d61a6f3c0b5d08df5c2fcdc","unresolved":false,"context_lines":[{"line_number":3841,"context_line":"                                                  instance\u003dinstance)"},{"line_number":3842,"context_line":"        with self._error_out_instance_on_exception("},{"line_number":3843,"context_line":"                context, instance, quotas\u003dquotas,"},{"line_number":3844,"context_line":"                instance_state\u003dinstance.vm_state):"},{"line_number":3845,"context_line":"            # TODO(chaochin) Remove this until v5 RPC API"},{"line_number":3846,"context_line":"            # Code downstream may expect extra_specs to be populated since it"},{"line_number":3847,"context_line":"            # is receiving an object, so lookup the flavor to ensure this."}],"source_content_type":"text/x-python","patch_set":7,"id":"3afc51ec_f7dc771a","line":3844,"range":{"start_line":3844,"start_character":16,"end_line":3844,"end_character":48},"in_reply_to":"5aef4532_83fb4b46","updated":"2016-03-11 14:31:57.000000000","message":"I don\u0027t think we can or should rely on the sync instance power states periodic task, because (1) it only runs every 10 minutes by default and (2) some deployments, like those running with vmware, disable the periodic task.\n\nMaybe the same logic from sync_instance_power_state could be reused here, or that method could be made to handle this case (you\u0027d have to force it to ignore the instance.task_state).","commit_id":"054633ec0577b2cda06447401f920e573b5f4859"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"f70f1b6fde364132022dbd5043ed64327a662162","unresolved":false,"context_lines":[{"line_number":3841,"context_line":"                                                  instance\u003dinstance)"},{"line_number":3842,"context_line":"        with self._error_out_instance_on_exception("},{"line_number":3843,"context_line":"                context, instance, quotas\u003dquotas,"},{"line_number":3844,"context_line":"                instance_state\u003dinstance.vm_state):"},{"line_number":3845,"context_line":"            # TODO(chaochin) Remove this until v5 RPC API"},{"line_number":3846,"context_line":"            # Code downstream may expect extra_specs to be populated since it"},{"line_number":3847,"context_line":"            # is receiving an object, so lookup the flavor to ensure this."}],"source_content_type":"text/x-python","patch_set":7,"id":"5aef4532_83fb4b46","line":3844,"range":{"start_line":3844,"start_character":16,"end_line":3844,"end_character":48},"in_reply_to":"5aef4532_ced93d24","updated":"2016-03-10 23:54:58.000000000","message":"As my understand, the sync of the inconsistent status between nova db and virt driver shouldn\u0027t be done at here. \u0027The _sync_instance_power_state\u0027 will take care of that.","commit_id":"054633ec0577b2cda06447401f920e573b5f4859"}],"nova/tests/unit/compute/test_compute.py":[{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"7b9df8d6f1e08aef719d6252637456730ca27d14","unresolved":false,"context_lines":[{"line_number":5061,"context_line":"        self.assertEqual(instance.vm_state, vm_states.ERROR)"},{"line_number":5062,"context_line":"        self.compute.terminate_instance(self.context, instance, [], [])"},{"line_number":5063,"context_line":""},{"line_number":5064,"context_line":"    def test_resize_active_instance_driver_rollback(self):"},{"line_number":5065,"context_line":"        self._test_resize_instance_driver_rollback(vm_states.ACTIVE)"},{"line_number":5066,"context_line":""},{"line_number":5067,"context_line":"    def test_resize_stopped_instance_driver_rollback(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"7af24918_641f3a5b","line":5064,"updated":"2016-03-04 09:55:31.000000000","message":"Maybe separate test for _rollback should be added too?","commit_id":"db570f2b04324bb63e0d1229f73bd263f271d1b0"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"d91c92ecf9b8579b61e060826254f69f0961fa96","unresolved":false,"context_lines":[{"line_number":5061,"context_line":"        self.assertEqual(instance.vm_state, vm_states.ERROR)"},{"line_number":5062,"context_line":"        self.compute.terminate_instance(self.context, instance, [], [])"},{"line_number":5063,"context_line":""},{"line_number":5064,"context_line":"    def test_resize_active_instance_driver_rollback(self):"},{"line_number":5065,"context_line":"        self._test_resize_instance_driver_rollback(vm_states.ACTIVE)"},{"line_number":5066,"context_line":""},{"line_number":5067,"context_line":"    def test_resize_stopped_instance_driver_rollback(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"7af24918_e44d0ac5","line":5064,"in_reply_to":"7af24918_641f3a5b","updated":"2016-03-04 10:06:15.000000000","message":"Done","commit_id":"db570f2b04324bb63e0d1229f73bd263f271d1b0"},{"author":{"_account_id":17898,"name":"Jinquan Ni","email":"ni.jinquan@zte.com.cn","username":"jinquanni"},"change_message_id":"e81ac790b13d43b7ac715ed3be4c351976bfdf33","unresolved":false,"context_lines":[{"line_number":5061,"context_line":"        self.assertEqual(instance.vm_state, vm_states.ERROR)"},{"line_number":5062,"context_line":"        self.compute.terminate_instance(self.context, instance, [], [])"},{"line_number":5063,"context_line":""},{"line_number":5064,"context_line":"    def test_resize_active_instance_driver_rollback(self):"},{"line_number":5065,"context_line":"        self._test_resize_instance_driver_rollback(vm_states.ACTIVE)"},{"line_number":5066,"context_line":""},{"line_number":5067,"context_line":"    def test_resize_stopped_instance_driver_rollback(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"5aef4532_c94a49c5","line":5064,"in_reply_to":"7af24918_641f3a5b","updated":"2016-03-08 08:44:22.000000000","message":"thank for your review，i will add in patch set 5","commit_id":"db570f2b04324bb63e0d1229f73bd263f271d1b0"},{"author":{"_account_id":17898,"name":"Jinquan Ni","email":"ni.jinquan@zte.com.cn","username":"jinquanni"},"change_message_id":"e81ac790b13d43b7ac715ed3be4c351976bfdf33","unresolved":false,"context_lines":[{"line_number":5061,"context_line":"        self.assertEqual(instance.vm_state, vm_states.ERROR)"},{"line_number":5062,"context_line":"        self.compute.terminate_instance(self.context, instance, [], [])"},{"line_number":5063,"context_line":""},{"line_number":5064,"context_line":"    def test_resize_active_instance_driver_rollback(self):"},{"line_number":5065,"context_line":"        self._test_resize_instance_driver_rollback(vm_states.ACTIVE)"},{"line_number":5066,"context_line":""},{"line_number":5067,"context_line":"    def test_resize_stopped_instance_driver_rollback(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"5aef4532_29392d42","line":5064,"in_reply_to":"7af24918_e44d0ac5","updated":"2016-03-08 08:44:22.000000000","message":"thank for your review，i will add in patch set 5","commit_id":"db570f2b04324bb63e0d1229f73bd263f271d1b0"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"10579dc50b03d63120f5f8f3e7a73a2a66174a71","unresolved":false,"context_lines":[{"line_number":5062,"context_line":"        self.compute.terminate_instance(self.context, instance, [], [])"},{"line_number":5063,"context_line":""},{"line_number":5064,"context_line":"    def test_resize_active_instance_driver_rollback(self):"},{"line_number":5065,"context_line":"        self._test_resize_instance_driver_rollback(vm_states.ACTIVE)"},{"line_number":5066,"context_line":""},{"line_number":5067,"context_line":"    def test_resize_stopped_instance_driver_rollback(self):"},{"line_number":5068,"context_line":"        self._test_resize_instance_driver_rollback(vm_states.STOPPED)"}],"source_content_type":"text/x-python","patch_set":4,"id":"7af24918_640bba7d","line":5065,"updated":"2016-03-04 10:05:43.000000000","message":"Maybe test for _rollback should be added too?","commit_id":"db570f2b04324bb63e0d1229f73bd263f271d1b0"},{"author":{"_account_id":17898,"name":"Jinquan Ni","email":"ni.jinquan@zte.com.cn","username":"jinquanni"},"change_message_id":"e81ac790b13d43b7ac715ed3be4c351976bfdf33","unresolved":false,"context_lines":[{"line_number":5062,"context_line":"        self.compute.terminate_instance(self.context, instance, [], [])"},{"line_number":5063,"context_line":""},{"line_number":5064,"context_line":"    def test_resize_active_instance_driver_rollback(self):"},{"line_number":5065,"context_line":"        self._test_resize_instance_driver_rollback(vm_states.ACTIVE)"},{"line_number":5066,"context_line":""},{"line_number":5067,"context_line":"    def test_resize_stopped_instance_driver_rollback(self):"},{"line_number":5068,"context_line":"        self._test_resize_instance_driver_rollback(vm_states.STOPPED)"}],"source_content_type":"text/x-python","patch_set":4,"id":"5aef4532_091391b9","line":5065,"in_reply_to":"7af24918_640bba7d","updated":"2016-03-08 08:44:22.000000000","message":"thank for your review，i will add in patch set 5","commit_id":"db570f2b04324bb63e0d1229f73bd263f271d1b0"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"56b4cbd4150bc891fdf5910c95c9fc05d25ee7c0","unresolved":false,"context_lines":[{"line_number":5111,"context_line":""},{"line_number":5112,"context_line":"    def test_rollback_instance_state_to_origin_state(self):"},{"line_number":5113,"context_line":"        instance \u003d self._create_fake_instance_obj()"},{"line_number":5114,"context_line":"        self.compute.build_and_run_instance(self.context, instance, {}, {}, {},"},{"line_number":5115,"context_line":"                                            block_device_mapping\u003d[])"},{"line_number":5116,"context_line":"        instance.host \u003d \u0027foo\u0027"},{"line_number":5117,"context_line":"        instance.save()"},{"line_number":5118,"context_line":"        instance_origin_state \u003d vm_states.STOPPED"}],"source_content_type":"text/x-python","patch_set":5,"id":"5aef4532_cd8507ae","line":5115,"range":{"start_line":5114,"start_character":8,"end_line":5115,"end_character":68},"updated":"2016-03-09 02:22:47.000000000","message":"nit, this looks like needless.","commit_id":"3377c69f59ec0a12eb1d8600ae0ffbb14fddaeb7"},{"author":{"_account_id":17898,"name":"Jinquan Ni","email":"ni.jinquan@zte.com.cn","username":"jinquanni"},"change_message_id":"ad1f5be8087d84a3ead4a624afd5fd2ddba105d7","unresolved":false,"context_lines":[{"line_number":5111,"context_line":""},{"line_number":5112,"context_line":"    def test_rollback_instance_state_to_origin_state(self):"},{"line_number":5113,"context_line":"        instance \u003d self._create_fake_instance_obj()"},{"line_number":5114,"context_line":"        self.compute.build_and_run_instance(self.context, instance, {}, {}, {},"},{"line_number":5115,"context_line":"                                            block_device_mapping\u003d[])"},{"line_number":5116,"context_line":"        instance.host \u003d \u0027foo\u0027"},{"line_number":5117,"context_line":"        instance.save()"},{"line_number":5118,"context_line":"        instance_origin_state \u003d vm_states.STOPPED"}],"source_content_type":"text/x-python","patch_set":5,"id":"5aef4532_012cd8a9","line":5115,"range":{"start_line":5114,"start_character":8,"end_line":5115,"end_character":68},"in_reply_to":"5aef4532_cd8507ae","updated":"2016-03-09 05:20:55.000000000","message":"Done","commit_id":"3377c69f59ec0a12eb1d8600ae0ffbb14fddaeb7"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"56b4cbd4150bc891fdf5910c95c9fc05d25ee7c0","unresolved":false,"context_lines":[{"line_number":5118,"context_line":"        instance_origin_state \u003d vm_states.STOPPED"},{"line_number":5119,"context_line":"        error_msg \u003d \u0027fake_error\u0027"},{"line_number":5120,"context_line":"        self.compute._rollback(self.context, error_msg, instance_origin_state,"},{"line_number":5121,"context_line":"                               instance, self.none_quotas)"},{"line_number":5122,"context_line":"        self.assertEqual(instance.vm_state, instance_origin_state)"},{"line_number":5123,"context_line":""},{"line_number":5124,"context_line":"    def _test_resize_instance(self, clean_shutdown\u003dTrue):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5aef4532_2dac6b33","line":5121,"range":{"start_line":5121,"start_character":41,"end_line":5121,"end_character":57},"updated":"2016-03-09 02:22:47.000000000","message":"It would better to ensure quotas rollback was called.","commit_id":"3377c69f59ec0a12eb1d8600ae0ffbb14fddaeb7"},{"author":{"_account_id":17898,"name":"Jinquan Ni","email":"ni.jinquan@zte.com.cn","username":"jinquanni"},"change_message_id":"ad1f5be8087d84a3ead4a624afd5fd2ddba105d7","unresolved":false,"context_lines":[{"line_number":5118,"context_line":"        instance_origin_state \u003d vm_states.STOPPED"},{"line_number":5119,"context_line":"        error_msg \u003d \u0027fake_error\u0027"},{"line_number":5120,"context_line":"        self.compute._rollback(self.context, error_msg, instance_origin_state,"},{"line_number":5121,"context_line":"                               instance, self.none_quotas)"},{"line_number":5122,"context_line":"        self.assertEqual(instance.vm_state, instance_origin_state)"},{"line_number":5123,"context_line":""},{"line_number":5124,"context_line":"    def _test_resize_instance(self, clean_shutdown\u003dTrue):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5aef4532_411c2077","line":5121,"range":{"start_line":5121,"start_character":41,"end_line":5121,"end_character":57},"in_reply_to":"5aef4532_2dac6b33","updated":"2016-03-09 05:20:55.000000000","message":"Done","commit_id":"3377c69f59ec0a12eb1d8600ae0ffbb14fddaeb7"}]}
