)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bb9555197ba3f11b2a1318b61b2cb482a3c56c1d","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     John Garbutt \u003cjohn.garbutt@rackspace.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2013-08-05 18:26:16 +0100"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"xenapi: we should retry glance upload on sigterm"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Sometimes the glance upload will get killed. We should retry the glance"},{"line_number":10,"context_line":"upload on these types of errors."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"AAAAQn%2F%2FMWQ%3D","line":7,"updated":"2013-08-05 17:40:47.000000000","message":"You\u0027re checking for more than just a sigterm in this patch, maybe you should make the commit message more generic, e.g. \"xenapi: we should retry glance upload on certain errors\" or something like that?  Just noting it because of the \u0027RetryableError\u0027 case.","commit_id":"7f1001484dfba4db347f258f4f53e625eb4cdf4b"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"0e5dc83800411b80f298e244638ea246c9143678","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     John Garbutt \u003cjohn.garbutt@rackspace.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2013-08-05 18:26:16 +0100"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"xenapi: we should retry glance upload on sigterm"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Sometimes the glance upload will get killed. We should retry the glance"},{"line_number":10,"context_line":"upload on these types of errors."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"AAAAQn%2F%2FJxU%3D","line":7,"in_reply_to":"AAAAQn%2F%2FMWQ%3D","updated":"2013-08-06 10:01:43.000000000","message":"Yes, I need to re-write this all really, the change isn\u0027t really what it was in the first place.","commit_id":"7f1001484dfba4db347f258f4f53e625eb4cdf4b"}],"nova/tests/virt/xenapi/image/test_glance.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bb9555197ba3f11b2a1318b61b2cb482a3c56c1d","unresolved":false,"context_lines":[{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        self.store.upload_image(self.context, self.session, self.instance,"},{"line_number":96,"context_line":"                                [\u0027fake_vdi_uuid\u0027], \u0027fake_image_uuid\u0027)"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"        self.mox.VerifyAll()"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAQn%2F%2FMV4%3D","side":"PARENT","line":97,"updated":"2013-08-05 17:40:47.000000000","message":"Looks like an unnecessary whitespace change here.","commit_id":"d09f77b1fc5b69b01f79f7433221675e07fab69b"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"0e5dc83800411b80f298e244638ea246c9143678","unresolved":false,"context_lines":[{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        self.store.upload_image(self.context, self.session, self.instance,"},{"line_number":96,"context_line":"                                [\u0027fake_vdi_uuid\u0027], \u0027fake_image_uuid\u0027)"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"        self.mox.VerifyAll()"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAQn%2F%2FJxY%3D","side":"PARENT","line":97,"in_reply_to":"AAAAQn%2F%2FMV4%3D","updated":"2013-08-06 10:01:43.000000000","message":"the old test doesn\u0027t really exist in the new code, but I could keep the old formatting in the new code, if that is preferred.","commit_id":"d09f77b1fc5b69b01f79f7433221675e07fab69b"}],"nova/virt/xenapi/driver.py":[{"author":{"_account_id":5044,"name":"Mate Lakat","email":"mlakat@suse.com","username":"mate-lakat"},"change_message_id":"c2885cdcb6c12af5a8d04b0f8b04e5cf2c74edf3","unresolved":false,"context_lines":[{"line_number":756,"context_line":"                if callback:"},{"line_number":757,"context_line":"                    callback(kwargs)"},{"line_number":758,"context_line":"                return self.call_plugin_serialized(plugin, fn, *args, **kwargs)"},{"line_number":759,"context_line":"            except self.XenAPI.Failure as exc:"},{"line_number":760,"context_line":"                LOG.exception(_(\u0027%(plugin)s.%(fn)s failed.\u0027) %"},{"line_number":761,"context_line":"                              {\u0027plugin\u0027: plugin, \u0027fn\u0027: fn})"},{"line_number":762,"context_line":"                _type, method, error \u003d exc.details[:3]"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAQn%2F%2FKF0%3D","line":759,"updated":"2013-08-06 08:17:52.000000000","message":"I would like to see this logic to be extracted to a function, not inlined here. We already have too long methods, and they are really hard to test/reuse. Think about something like is_retryable_exception(exc). It will make your tests smaller!","commit_id":"7f1001484dfba4db347f258f4f53e625eb4cdf4b"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"0e5dc83800411b80f298e244638ea246c9143678","unresolved":false,"context_lines":[{"line_number":756,"context_line":"                if callback:"},{"line_number":757,"context_line":"                    callback(kwargs)"},{"line_number":758,"context_line":"                return self.call_plugin_serialized(plugin, fn, *args, **kwargs)"},{"line_number":759,"context_line":"            except self.XenAPI.Failure as exc:"},{"line_number":760,"context_line":"                LOG.exception(_(\u0027%(plugin)s.%(fn)s failed.\u0027) %"},{"line_number":761,"context_line":"                              {\u0027plugin\u0027: plugin, \u0027fn\u0027: fn})"},{"line_number":762,"context_line":"                _type, method, error \u003d exc.details[:3]"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAQn%2F%2FJxk%3D","line":759,"in_reply_to":"AAAAQn%2F%2FKF0%3D","updated":"2013-08-06 10:01:43.000000000","message":"yeah, I was trying to reduce code churn, but there is no point in that really.","commit_id":"7f1001484dfba4db347f258f4f53e625eb4cdf4b"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bb9555197ba3f11b2a1318b61b2cb482a3c56c1d","unresolved":false,"context_lines":[{"line_number":757,"context_line":"                    callback(kwargs)"},{"line_number":758,"context_line":"                return self.call_plugin_serialized(plugin, fn, *args, **kwargs)"},{"line_number":759,"context_line":"            except self.XenAPI.Failure as exc:"},{"line_number":760,"context_line":"                LOG.exception(_(\u0027%(plugin)s.%(fn)s failed.\u0027) %"},{"line_number":761,"context_line":"                              {\u0027plugin\u0027: plugin, \u0027fn\u0027: fn})"},{"line_number":762,"context_line":"                _type, method, error \u003d exc.details[:3]"},{"line_number":763,"context_line":"                if error \u003d\u003d \u0027RetryableError\u0027:"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAQn%2F%2FMWo%3D","line":760,"updated":"2013-08-05 17:40:47.000000000","message":"If you\u0027re going to retry, I think this should be logged as a warning to avoid the stack trace.  See Sean Dague\u0027s comments here:\n\nhttps://review.openstack.org/#/c/38085/1/nova/virt/libvirt/driver.py","commit_id":"7f1001484dfba4db347f258f4f53e625eb4cdf4b"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"0e5dc83800411b80f298e244638ea246c9143678","unresolved":false,"context_lines":[{"line_number":757,"context_line":"                    callback(kwargs)"},{"line_number":758,"context_line":"                return self.call_plugin_serialized(plugin, fn, *args, **kwargs)"},{"line_number":759,"context_line":"            except self.XenAPI.Failure as exc:"},{"line_number":760,"context_line":"                LOG.exception(_(\u0027%(plugin)s.%(fn)s failed.\u0027) %"},{"line_number":761,"context_line":"                              {\u0027plugin\u0027: plugin, \u0027fn\u0027: fn})"},{"line_number":762,"context_line":"                _type, method, error \u003d exc.details[:3]"},{"line_number":763,"context_line":"                if error \u003d\u003d \u0027RetryableError\u0027:"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAQn%2F%2FJx4%3D","line":760,"in_reply_to":"AAAAQn%2F%2FMWo%3D","updated":"2013-08-06 10:01:43.000000000","message":"I do want the stack trace, but this should be an warn, I was just trying to keep the same behavior as before, we may as well fix that at the same time I guess.","commit_id":"7f1001484dfba4db347f258f4f53e625eb4cdf4b"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bb9555197ba3f11b2a1318b61b2cb482a3c56c1d","unresolved":false,"context_lines":[{"line_number":761,"context_line":"                              {\u0027plugin\u0027: plugin, \u0027fn\u0027: fn})"},{"line_number":762,"context_line":"                _type, method, error \u003d exc.details[:3]"},{"line_number":763,"context_line":"                if error \u003d\u003d \u0027RetryableError\u0027:"},{"line_number":764,"context_line":"                    LOG.debug(_(\"RetryableErorr so retrying upload_vhd\"))"},{"line_number":765,"context_line":"                elif \"signal\" in method:"},{"line_number":766,"context_line":"                    LOG.debug(_(\"Error due to a signal, retrying upload_vhd\"))"},{"line_number":767,"context_line":"                else:"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAQn%2F%2FMWk%3D","line":764,"updated":"2013-08-05 17:40:47.000000000","message":"s/Erorr/Error","commit_id":"7f1001484dfba4db347f258f4f53e625eb4cdf4b"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bf25adb7f715088d03bf78b16120e8ec908848bb","unresolved":false,"context_lines":[{"line_number":770,"context_line":""},{"line_number":771,"context_line":"    def _is_retryable_exception(self, exc):"},{"line_number":772,"context_line":"        _type, method, error \u003d exc.details[:3]"},{"line_number":773,"context_line":"        if error \u003d\u003d \u0027RetryableError\u0027:"},{"line_number":774,"context_line":"            LOG.debug(_(\"RetryableError, so retrying upload_vhd\"),"},{"line_number":775,"context_line":"                      exc_info\u003dTrue)"},{"line_number":776,"context_line":"            return True"}],"source_content_type":"text/x-python","patch_set":3,"id":"AAAAQn%2F%2FJMU%3D","line":773,"updated":"2013-08-06 14:19:12.000000000","message":"This might be better as: if \u0027RetryableError\u0027 in error:\n\nJust thinking about future-proofing.","commit_id":"34d93b3b2b7029ebf86123aeb1116c7cd824d8f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"748e46015b14275ccf41c1c2b554837fd934420e","unresolved":false,"context_lines":[{"line_number":770,"context_line":""},{"line_number":771,"context_line":"    def _is_retryable_exception(self, exc):"},{"line_number":772,"context_line":"        _type, method, error \u003d exc.details[:3]"},{"line_number":773,"context_line":"        if error \u003d\u003d \u0027RetryableError\u0027:"},{"line_number":774,"context_line":"            LOG.debug(_(\"RetryableError, so retrying upload_vhd\"),"},{"line_number":775,"context_line":"                      exc_info\u003dTrue)"},{"line_number":776,"context_line":"            return True"}],"source_content_type":"text/x-python","patch_set":3,"id":"AAAAQn%2F%2FJKk%3D","line":773,"in_reply_to":"AAAAQn%2F%2FJLo%3D","updated":"2013-08-06 14:27:15.000000000","message":"Fair enough.  Hopefully I never have to say I told you so. :)","commit_id":"34d93b3b2b7029ebf86123aeb1116c7cd824d8f3"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"d61ecf999e596ccf9ac91ea2be26665d06b47c27","unresolved":false,"context_lines":[{"line_number":770,"context_line":""},{"line_number":771,"context_line":"    def _is_retryable_exception(self, exc):"},{"line_number":772,"context_line":"        _type, method, error \u003d exc.details[:3]"},{"line_number":773,"context_line":"        if error \u003d\u003d \u0027RetryableError\u0027:"},{"line_number":774,"context_line":"            LOG.debug(_(\"RetryableError, so retrying upload_vhd\"),"},{"line_number":775,"context_line":"                      exc_info\u003dTrue)"},{"line_number":776,"context_line":"            return True"}],"source_content_type":"text/x-python","patch_set":3,"id":"AAAAQn%2F%2FJLo%3D","line":773,"in_reply_to":"AAAAQn%2F%2FJMU%3D","updated":"2013-08-06 14:22:50.000000000","message":"I like the idea, but its a type name output by the RPC, so its not likely to change. I will update that if I need to make a change for another reason.","commit_id":"34d93b3b2b7029ebf86123aeb1116c7cd824d8f3"}],"nova/virt/xenapi/imageupload/glance.py":[{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"67fa1247b1d41d68a939c7280de57b5bc5510ea7","unresolved":false,"context_lines":[{"line_number":88,"context_line":"                if error \u003d\u003d \u0027RetryableError\u0027:"},{"line_number":89,"context_line":"                    LOG.debug(_(\"RetryableErorr so retrying upload_vhd\"))"},{"line_number":90,"context_line":"                elif \"signal\" in method:"},{"line_number":91,"context_line":"                    LOG.debug(_(\"Error due to a signal, retrying upload_vhd\"))"},{"line_number":92,"context_line":"                else:"},{"line_number":93,"context_line":"                    raise"},{"line_number":94,"context_line":"            time.sleep(sleep_time)"}],"source_content_type":"text/x-python","patch_set":1,"id":"AAAAQn%2F%2FSgE%3D","line":91,"updated":"2013-08-02 14:30:13.000000000","message":"I\u0027ll just assume you tested this \"signal\" business. :)\n\nShould we manipulate sleep_time in this case knowing that something on the xapi side is probably restarting?  If it errors on the first attempt, the code only sleeps for 0.5 seconds.","commit_id":"65af8511953cdb98b3a0088513cc970e56089ce6"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"27c050c89c305e1c3e4eb445683af4fd43f52f7f","unresolved":false,"context_lines":[{"line_number":88,"context_line":"                if error \u003d\u003d \u0027RetryableError\u0027:"},{"line_number":89,"context_line":"                    LOG.debug(_(\"RetryableErorr so retrying upload_vhd\"))"},{"line_number":90,"context_line":"                elif \"signal\" in method:"},{"line_number":91,"context_line":"                    LOG.debug(_(\"Error due to a signal, retrying upload_vhd\"))"},{"line_number":92,"context_line":"                else:"},{"line_number":93,"context_line":"                    raise"},{"line_number":94,"context_line":"            time.sleep(sleep_time)"}],"source_content_type":"text/x-python","patch_set":1,"id":"AAAAQn%2F%2FRvA%3D","line":91,"in_reply_to":"AAAAQn%2F%2FSgE%3D","updated":"2013-08-02 17:46:47.000000000","message":"It seems much more odd than that though :( It gets killed due to something I haven\u0027t found yet, so an immediate try should be OK.","commit_id":"65af8511953cdb98b3a0088513cc970e56089ce6"}]}
