)]}'
{"cinder/backup/driver.py":[{"author":{"_account_id":4523,"name":"Eric Harney","email":"eharney@redhat.com","username":"eharney"},"change_message_id":"fd69ed3a0531fc46403084a22fc4d5cf88f51f8f","unresolved":false,"context_lines":[{"line_number":410,"context_line":"        \"\"\""},{"line_number":411,"context_line":"        return"},{"line_number":412,"context_line":""},{"line_number":413,"context_line":"    def check_for_setup_errors(self):"},{"line_number":414,"context_line":"        \"\"\"Method for checking if backup backend is successfully installed.\"\"\""},{"line_number":415,"context_line":"        return"},{"line_number":416,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"7f231b9d_9506db1f","line":413,"range":{"start_line":413,"start_character":8,"end_line":413,"end_character":30},"updated":"2017-06-16 13:03:13.000000000","message":"Should be named check_for_setup_error() to match the volume drivers\u0027 method -- having a similar but different name will be confusing.","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":23602,"name":"Michael Dovgal","email":"dovgalmichael@gmail.com","username":"mdovgal"},"change_message_id":"d8b3ab3a4124d8ce15fc462273bca93a54ec874f","unresolved":false,"context_lines":[{"line_number":410,"context_line":"        \"\"\""},{"line_number":411,"context_line":"        return"},{"line_number":412,"context_line":""},{"line_number":413,"context_line":"    def check_for_setup_errors(self):"},{"line_number":414,"context_line":"        \"\"\"Method for checking if backup backend is successfully installed.\"\"\""},{"line_number":415,"context_line":"        return"},{"line_number":416,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"7f231b9d_f8ebc674","line":413,"range":{"start_line":413,"start_character":8,"end_line":413,"end_character":30},"in_reply_to":"7f231b9d_9506db1f","updated":"2017-06-16 13:48:20.000000000","message":"true...thanks","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"7f9d8eb141cc28d02bda62e1fb0cfa64b6effccc","unresolved":false,"context_lines":[{"line_number":410,"context_line":"        \"\"\""},{"line_number":411,"context_line":"        return"},{"line_number":412,"context_line":""},{"line_number":413,"context_line":"    def check_for_setup_error(self):"},{"line_number":414,"context_line":"        \"\"\"Method for checking if backup backend is successfully installed.\"\"\""},{"line_number":415,"context_line":"        return"},{"line_number":416,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"3f1d235d_5968981b","line":413,"updated":"2017-07-05 15:22:46.000000000","message":"Can you add this here [1] with a full docstring explaining what is expected of a backup driver for this call?\n\n[1] https://github.com/openstack/cinder/blob/master/cinder/interface/backup_driver.py","commit_id":"729aef6fe85657bd7d630129dd332bcd7a131248"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"2aef4509ce9dd271e6c5387eaad5d6026ebe55da","unresolved":false,"context_lines":[{"line_number":410,"context_line":"        \"\"\""},{"line_number":411,"context_line":"        return"},{"line_number":412,"context_line":""},{"line_number":413,"context_line":"    def check_for_setup_error(self):"},{"line_number":414,"context_line":"        \"\"\"Method for checking if backup backend is successfully installed.\"\"\""},{"line_number":415,"context_line":"        return"},{"line_number":416,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"3f1d235d_3e759ffa","line":413,"in_reply_to":"3f1d235d_5968981b","updated":"2017-07-06 10:29:32.000000000","message":"Done","commit_id":"729aef6fe85657bd7d630129dd332bcd7a131248"}],"cinder/backup/drivers/ceph.py":[{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"5360a56b96b659035261b185e481eafe55ca7811","unresolved":false,"context_lines":[{"line_number":271,"context_line":"        \"\"\"Returns an error if prerequisites aren\u0027t met.\"\"\""},{"line_number":272,"context_line":"        if rados is None or rbd is None:"},{"line_number":273,"context_line":"            msg \u003d _(\u0027rados and rbd python libraries not found\u0027)"},{"line_number":274,"context_line":"            raise exception.BackupOperationError(data\u003dmsg)"},{"line_number":275,"context_line":""},{"line_number":276,"context_line":"        for attr in [\u0027backup_ceph_user\u0027, \u0027backup_ceph_pool\u0027,"},{"line_number":277,"context_line":"                     \u0027backup_ceph_conf\u0027]:"}],"source_content_type":"text/x-python","patch_set":12,"id":"1f1a1f67_cdf9c4c8","line":274,"range":{"start_line":274,"start_character":49,"end_line":274,"end_character":53},"updated":"2017-07-14 20:54:34.000000000","message":"BackupOperationError does not take a \"data\" param.  This will raise an exception itself.\n\nclass BackupOperationError(Invalid):\n    message \u003d _(\"An error has occurred during backup operation\")","commit_id":"db65cd6127aa025356f3e3a09d54a443f242300c"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"ece82d97f60beede3334aa7514560da6eb2d5e22","unresolved":false,"context_lines":[{"line_number":271,"context_line":"        \"\"\"Returns an error if prerequisites aren\u0027t met.\"\"\""},{"line_number":272,"context_line":"        if rados is None or rbd is None:"},{"line_number":273,"context_line":"            msg \u003d _(\u0027rados and rbd python libraries not found\u0027)"},{"line_number":274,"context_line":"            raise exception.BackupOperationError(data\u003dmsg)"},{"line_number":275,"context_line":""},{"line_number":276,"context_line":"        for attr in [\u0027backup_ceph_user\u0027, \u0027backup_ceph_pool\u0027,"},{"line_number":277,"context_line":"                     \u0027backup_ceph_conf\u0027]:"}],"source_content_type":"text/x-python","patch_set":12,"id":"ff346bd7_87b291e5","line":274,"range":{"start_line":274,"start_character":49,"end_line":274,"end_character":53},"in_reply_to":"1f1a1f67_1799f477","updated":"2017-07-25 07:58:55.000000000","message":"Done","commit_id":"db65cd6127aa025356f3e3a09d54a443f242300c"},{"author":{"_account_id":23083,"name":"TommyLike","email":"tommylikehu@gmail.com","username":"TommyLike"},"change_message_id":"b7bd548b86cf5dc751d3e1f083fa8c4d0b87ac46","unresolved":false,"context_lines":[{"line_number":271,"context_line":"        \"\"\"Returns an error if prerequisites aren\u0027t met.\"\"\""},{"line_number":272,"context_line":"        if rados is None or rbd is None:"},{"line_number":273,"context_line":"            msg \u003d _(\u0027rados and rbd python libraries not found\u0027)"},{"line_number":274,"context_line":"            raise exception.BackupOperationError(data\u003dmsg)"},{"line_number":275,"context_line":""},{"line_number":276,"context_line":"        for attr in [\u0027backup_ceph_user\u0027, \u0027backup_ceph_pool\u0027,"},{"line_number":277,"context_line":"                     \u0027backup_ceph_conf\u0027]:"}],"source_content_type":"text/x-python","patch_set":12,"id":"1f1a1f67_1799f477","line":274,"range":{"start_line":274,"start_character":49,"end_line":274,"end_character":53},"in_reply_to":"1f1a1f67_cdf9c4c8","updated":"2017-07-17 01:48:23.000000000","message":"+1","commit_id":"db65cd6127aa025356f3e3a09d54a443f242300c"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"d597d7dba0bfee5cb9ec6016e7efb42734f5bafa","unresolved":false,"context_lines":[{"line_number":271,"context_line":"        \"\"\"Returns an error if prerequisites aren\u0027t met.\"\"\""},{"line_number":272,"context_line":"        if rados is None or rbd is None:"},{"line_number":273,"context_line":"            msg \u003d _(\u0027rados and rbd python libraries not found\u0027)"},{"line_number":274,"context_line":"            raise exception.BackupDriverException(data\u003dmsg)"},{"line_number":275,"context_line":""},{"line_number":276,"context_line":"        for attr in [\u0027backup_ceph_user\u0027, \u0027backup_ceph_pool\u0027,"},{"line_number":277,"context_line":"                     \u0027backup_ceph_conf\u0027]:"}],"source_content_type":"text/x-python","patch_set":17,"id":"ff346bd7_0c70fddb","line":274,"updated":"2017-07-25 12:56:33.000000000","message":"Should be exception.BackupDriverException(message\u003dmsg).\n\nclass BackupDriverException(CinderException):\n    message \u003d _(\"Backup driver reported an error: %(message)s\")","commit_id":"bb2abc8840ed9c97afe5b70a0f74ae79e215deac"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"1926589ed27e5336ed506563dded4627fe685e57","unresolved":false,"context_lines":[{"line_number":271,"context_line":"        \"\"\"Returns an error if prerequisites aren\u0027t met.\"\"\""},{"line_number":272,"context_line":"        if rados is None or rbd is None:"},{"line_number":273,"context_line":"            msg \u003d _(\u0027rados and rbd python libraries not found\u0027)"},{"line_number":274,"context_line":"            raise exception.BackupDriverException(data\u003dmsg)"},{"line_number":275,"context_line":""},{"line_number":276,"context_line":"        for attr in [\u0027backup_ceph_user\u0027, \u0027backup_ceph_pool\u0027,"},{"line_number":277,"context_line":"                     \u0027backup_ceph_conf\u0027]:"}],"source_content_type":"text/x-python","patch_set":17,"id":"ff346bd7_ade68b43","line":274,"in_reply_to":"ff346bd7_0c70fddb","updated":"2017-07-25 13:56:22.000000000","message":"Done, thanks a lot!","commit_id":"bb2abc8840ed9c97afe5b70a0f74ae79e215deac"}],"cinder/backup/drivers/swift.py":[{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"e16d4e4d9207f3b8b4bf54a718ec5e31d0dc593b","unresolved":false,"context_lines":[{"line_number":147,"context_line":"        if hasattr(obj, \u0027initialized\u0027):"},{"line_number":148,"context_line":"            if not obj.initialized:"},{"line_number":149,"context_line":"                try:"},{"line_number":150,"context_line":"                    obj._initialize()"},{"line_number":151,"context_line":"                    obj.initialized \u003d True"},{"line_number":152,"context_line":"                except Exception:"},{"line_number":153,"context_line":"                    pass"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_bfd0d054","line":150,"updated":"2017-03-20 12:45:31.000000000","message":"Please, add a comment why do we need this method for Swift only and why this method should be private","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"e16d4e4d9207f3b8b4bf54a718ec5e31d0dc593b","unresolved":false,"context_lines":[{"line_number":148,"context_line":"            if not obj.initialized:"},{"line_number":149,"context_line":"                try:"},{"line_number":150,"context_line":"                    obj._initialize()"},{"line_number":151,"context_line":"                    obj.initialized \u003d True"},{"line_number":152,"context_line":"                except Exception:"},{"line_number":153,"context_line":"                    pass"},{"line_number":154,"context_line":"        method(obj, *args, **kwargs)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_1f800446","line":151,"updated":"2017-03-20 12:45:31.000000000","message":"Why you don\u0027t set initialized\u003dTrue inside _initialize method?","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"2d5f90ab491261d7f3b0a04584d8d6ebb0c99768","unresolved":false,"context_lines":[{"line_number":174,"context_line":"    initialized \u003d False"},{"line_number":175,"context_line":""},{"line_number":176,"context_line":"    def __init__(self, context, db_driver\u003dNone):"},{"line_number":177,"context_line":"        # NOTE (mdovgal): just to save this parameters to use it after"},{"line_number":178,"context_line":"        # in initialize method"},{"line_number":179,"context_line":"        self.save_context \u003d context"},{"line_number":180,"context_line":"        self.save_db_driver \u003d db_driver"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_f72ac82b","line":177,"range":{"start_line":177,"start_character":62,"end_line":177,"end_character":64},"updated":"2017-03-16 17:40:55.000000000","message":"s/it/them","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"2d5f90ab491261d7f3b0a04584d8d6ebb0c99768","unresolved":false,"context_lines":[{"line_number":174,"context_line":"    initialized \u003d False"},{"line_number":175,"context_line":""},{"line_number":176,"context_line":"    def __init__(self, context, db_driver\u003dNone):"},{"line_number":177,"context_line":"        # NOTE (mdovgal): just to save this parameters to use it after"},{"line_number":178,"context_line":"        # in initialize method"},{"line_number":179,"context_line":"        self.save_context \u003d context"},{"line_number":180,"context_line":"        self.save_db_driver \u003d db_driver"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_972b5433","line":177,"range":{"start_line":177,"start_character":39,"end_line":177,"end_character":43},"updated":"2017-03-16 17:40:55.000000000","message":"s/this/these","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"2d5f90ab491261d7f3b0a04584d8d6ebb0c99768","unresolved":false,"context_lines":[{"line_number":175,"context_line":""},{"line_number":176,"context_line":"    def __init__(self, context, db_driver\u003dNone):"},{"line_number":177,"context_line":"        # NOTE (mdovgal): just to save this parameters to use it after"},{"line_number":178,"context_line":"        # in initialize method"},{"line_number":179,"context_line":"        self.save_context \u003d context"},{"line_number":180,"context_line":"        self.save_db_driver \u003d db_driver"},{"line_number":181,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_7717b8ed","line":178,"range":{"start_line":178,"start_character":10,"end_line":178,"end_character":12},"updated":"2017-03-16 17:40:55.000000000","message":"s/in/the","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"e16d4e4d9207f3b8b4bf54a718ec5e31d0dc593b","unresolved":false,"context_lines":[{"line_number":406,"context_line":"        # At the moment of execution we don\u0027t have any user data"},{"line_number":407,"context_line":"        # After just trying to do easiest operations, that will show"},{"line_number":408,"context_line":"        # that we\u0027ve configured swift backup driver in right way"},{"line_number":409,"context_line":"        if not CONF.backup_swift_url:"},{"line_number":410,"context_line":"            raise Exception(\"Backup swift url wasn\u0027t found\")"},{"line_number":411,"context_line":"        conn \u003d swift.Connection(retries\u003dCONF.backup_swift_retry_attempts,"},{"line_number":412,"context_line":"                                preauthurl\u003dCONF.backup_swift_url)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_1f456416","line":409,"updated":"2017-03-20 12:45:31.000000000","message":"We can work w/o backup_swift_url param if we can retrieve it from the keystone","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"2d5f90ab491261d7f3b0a04584d8d6ebb0c99768","unresolved":false,"context_lines":[{"line_number":407,"context_line":"        # After just trying to do easiest operations, that will show"},{"line_number":408,"context_line":"        # that we\u0027ve configured swift backup driver in right way"},{"line_number":409,"context_line":"        if not CONF.backup_swift_url:"},{"line_number":410,"context_line":"            raise Exception(\"Backup swift url wasn\u0027t found\")"},{"line_number":411,"context_line":"        conn \u003d swift.Connection(retries\u003dCONF.backup_swift_retry_attempts,"},{"line_number":412,"context_line":"                                preauthurl\u003dCONF.backup_swift_url)"},{"line_number":413,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_37c1c081","line":410,"range":{"start_line":410,"start_character":18,"end_line":410,"end_character":27},"updated":"2017-03-16 17:40:55.000000000","message":"Please use a more specific exception.","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"2d5f90ab491261d7f3b0a04584d8d6ebb0c99768","unresolved":false,"context_lines":[{"line_number":407,"context_line":"        # After just trying to do easiest operations, that will show"},{"line_number":408,"context_line":"        # that we\u0027ve configured swift backup driver in right way"},{"line_number":409,"context_line":"        if not CONF.backup_swift_url:"},{"line_number":410,"context_line":"            raise Exception(\"Backup swift url wasn\u0027t found\")"},{"line_number":411,"context_line":"        conn \u003d swift.Connection(retries\u003dCONF.backup_swift_retry_attempts,"},{"line_number":412,"context_line":"                                preauthurl\u003dCONF.backup_swift_url)"},{"line_number":413,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_57be3c00","line":410,"range":{"start_line":410,"start_character":46,"end_line":410,"end_character":52},"updated":"2017-03-16 17:40:55.000000000","message":"isn\u0027t","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":23602,"name":"Michael Dovgal","email":"dovgalmichael@gmail.com","username":"mdovgal"},"change_message_id":"c1c756dc6b3b02654a2b998d01f7a798c12e49a3","unresolved":false,"context_lines":[{"line_number":407,"context_line":"        # After just trying to do easiest operations, that will show"},{"line_number":408,"context_line":"        # that we\u0027ve configured swift backup driver in right way"},{"line_number":409,"context_line":"        if not CONF.backup_swift_url:"},{"line_number":410,"context_line":"            raise Exception(\"Backup swift url wasn\u0027t found\")"},{"line_number":411,"context_line":"        conn \u003d swift.Connection(retries\u003dCONF.backup_swift_retry_attempts,"},{"line_number":412,"context_line":"                                preauthurl\u003dCONF.backup_swift_url)"},{"line_number":413,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_5610f54e","line":410,"range":{"start_line":410,"start_character":18,"end_line":410,"end_character":27},"in_reply_to":"1a1ced50_37c1c081","updated":"2017-03-16 22:47:55.000000000","message":"Yeah, sure. This exception now is added for tests.","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"b79712fde63d23a9c04de4a0d874c18480ceaea4","unresolved":false,"context_lines":[{"line_number":143,"context_line":"class SwiftBackupDriver(chunkeddriver.ChunkedBackupDriver):"},{"line_number":144,"context_line":"    \"\"\"Provides backup, restore and delete of backup objects within Swift.\"\"\""},{"line_number":145,"context_line":""},{"line_number":146,"context_line":"    def __init__(self, context, db_driver\u003dNone, need_to_init\u003dTrue):"},{"line_number":147,"context_line":"        chunk_size_bytes \u003d CONF.backup_swift_object_size"},{"line_number":148,"context_line":"        sha_block_size_bytes \u003d CONF.backup_swift_block_size"},{"line_number":149,"context_line":"        backup_default_container \u003d CONF.backup_swift_container"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f201791_cbf30c73","line":146,"updated":"2017-06-22 15:58:33.000000000","message":"In this case, we can just pass context\u003dNone instead of introducing new param","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"b79712fde63d23a9c04de4a0d874c18480ceaea4","unresolved":false,"context_lines":[{"line_number":154,"context_line":"                                                enable_progress_timer,"},{"line_number":155,"context_line":"                                                db_driver)"},{"line_number":156,"context_line":"        # added to prevent errors"},{"line_number":157,"context_line":"        if need_to_init:"},{"line_number":158,"context_line":"            self.initialize()"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"    def initialize(self):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f201791_4bfffc33","line":157,"updated":"2017-06-22 15:58:33.000000000","message":"Please, do something like:\nif context:\n    self.initialize()","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"9ea761679b84531e1e8fa423131d7748cc3cec8b","unresolved":false,"context_lines":[{"line_number":379,"context_line":"        # After just trying to do easiest operations, that will show"},{"line_number":380,"context_line":"        # that we\u0027ve configured swift backup driver in right way"},{"line_number":381,"context_line":"        if not CONF.backup_swift_url:"},{"line_number":382,"context_line":"            LOG.warning(\"We will use endpoints from keystone. Possible,\""},{"line_number":383,"context_line":"                        \"we could have problems because of it.\")"},{"line_number":384,"context_line":"            return"},{"line_number":385,"context_line":"        conn \u003d swift.Connection(retries\u003dCONF.backup_swift_retry_attempts,"}],"source_content_type":"text/x-python","patch_set":5,"id":"7f231b9d_35f6e764","line":382,"range":{"start_line":382,"start_character":71,"end_line":382,"end_character":72},"updated":"2017-06-16 12:50:34.000000000","message":"Need a space on the end.","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"9ea761679b84531e1e8fa423131d7748cc3cec8b","unresolved":false,"context_lines":[{"line_number":386,"context_line":"                                preauthurl\u003dCONF.backup_swift_url)"},{"line_number":387,"context_line":"        try:"},{"line_number":388,"context_line":"            conn.get_capabilities()"},{"line_number":389,"context_line":"        except Exception:"},{"line_number":390,"context_line":"            raise"},{"line_number":391,"context_line":""},{"line_number":392,"context_line":""},{"line_number":393,"context_line":"def get_backup_driver(context):"}],"source_content_type":"text/x-python","patch_set":5,"id":"7f231b9d_d5069352","line":390,"range":{"start_line":389,"start_character":8,"end_line":390,"end_character":17},"updated":"2017-06-16 12:50:34.000000000","message":"Is there a reason to catch and raise here?","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":23602,"name":"Michael Dovgal","email":"dovgalmichael@gmail.com","username":"mdovgal"},"change_message_id":"d8b3ab3a4124d8ce15fc462273bca93a54ec874f","unresolved":false,"context_lines":[{"line_number":386,"context_line":"                                preauthurl\u003dCONF.backup_swift_url)"},{"line_number":387,"context_line":"        try:"},{"line_number":388,"context_line":"            conn.get_capabilities()"},{"line_number":389,"context_line":"        except Exception:"},{"line_number":390,"context_line":"            raise"},{"line_number":391,"context_line":""},{"line_number":392,"context_line":""},{"line_number":393,"context_line":"def get_backup_driver(context):"}],"source_content_type":"text/x-python","patch_set":5,"id":"7f231b9d_ebf40ef3","line":390,"range":{"start_line":389,"start_character":8,"end_line":390,"end_character":17},"in_reply_to":"7f231b9d_d5069352","updated":"2017-06-16 13:48:20.000000000","message":"hm... agree. firstly the idea was to add some logs if we had an exception here. But seems I\u0027ve just forgotten about it...","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"7f9d8eb141cc28d02bda62e1fb0cfa64b6effccc","unresolved":false,"context_lines":[{"line_number":398,"context_line":"    #                we can\u0027t get all necessary information like endpoints"},{"line_number":399,"context_line":"    #                from context, so we have exception as a result."},{"line_number":400,"context_line":"    if context.user is None:"},{"line_number":401,"context_line":"        return SwiftBackupDriver(context)"},{"line_number":402,"context_line":"    return SwiftBackupDriver(context)"}],"source_content_type":"text/x-python","patch_set":9,"id":"3f1d235d_39fddc6d","line":401,"updated":"2017-07-05 15:22:46.000000000","message":"Maybe we should just log or something here since this is just duplicating what it already does?","commit_id":"729aef6fe85657bd7d630129dd332bcd7a131248"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"2aef4509ce9dd271e6c5387eaad5d6026ebe55da","unresolved":false,"context_lines":[{"line_number":398,"context_line":"    #                we can\u0027t get all necessary information like endpoints"},{"line_number":399,"context_line":"    #                from context, so we have exception as a result."},{"line_number":400,"context_line":"    if context.user is None:"},{"line_number":401,"context_line":"        return SwiftBackupDriver(context)"},{"line_number":402,"context_line":"    return SwiftBackupDriver(context)"}],"source_content_type":"text/x-python","patch_set":9,"id":"3f1d235d_befe4f68","line":401,"in_reply_to":"3f1d235d_39fddc6d","updated":"2017-07-06 10:29:32.000000000","message":"We should pass None to the driver in this case. I\u0027ll change it in a following patch","commit_id":"729aef6fe85657bd7d630129dd332bcd7a131248"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"5360a56b96b659035261b185e481eafe55ca7811","unresolved":false,"context_lines":[{"line_number":388,"context_line":"            conn.get_capabilities()"},{"line_number":389,"context_line":"            # TODO(e0ne) catch less general exception"},{"line_number":390,"context_line":"        except Exception:"},{"line_number":391,"context_line":"            LOG.exception(\"Can not get Swift capabilities\")"},{"line_number":392,"context_line":"            raise"},{"line_number":393,"context_line":""},{"line_number":394,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"1f1a1f67_0d9a1c62","line":391,"updated":"2017-07-14 20:54:34.000000000","message":"Can you add more info to this message, i.e., describe that this error happened while checking for setup errors.","commit_id":"db65cd6127aa025356f3e3a09d54a443f242300c"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"ece82d97f60beede3334aa7514560da6eb2d5e22","unresolved":false,"context_lines":[{"line_number":388,"context_line":"            conn.get_capabilities()"},{"line_number":389,"context_line":"            # TODO(e0ne) catch less general exception"},{"line_number":390,"context_line":"        except Exception:"},{"line_number":391,"context_line":"            LOG.exception(\"Can not get Swift capabilities\")"},{"line_number":392,"context_line":"            raise"},{"line_number":393,"context_line":""},{"line_number":394,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"ff346bd7_67ea0dad","line":391,"in_reply_to":"1f1a1f67_0d9a1c62","updated":"2017-07-25 07:58:55.000000000","message":"Done","commit_id":"db65cd6127aa025356f3e3a09d54a443f242300c"},{"author":{"_account_id":1207,"name":"Duncan Thomas","email":"duncan.thomas@gmail.com","username":"duncan-thomas"},"change_message_id":"2892daabb8cc456b93c3e631f991b75dd29c8107","unresolved":false,"context_lines":[{"line_number":153,"context_line":"                                                backup_default_container,"},{"line_number":154,"context_line":"                                                enable_progress_timer,"},{"line_number":155,"context_line":"                                                db)"},{"line_number":156,"context_line":"        # added to prevent errors"},{"line_number":157,"context_line":"        if context:"},{"line_number":158,"context_line":"            self.initialize()"},{"line_number":159,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"ff346bd7_41280e33","line":156,"range":{"start_line":156,"start_character":10,"end_line":156,"end_character":33},"updated":"2017-07-25 12:18:55.000000000","message":"This is an entirely unhelpful comment... Either we need a hint as to the errors prevented, or else the comment shouldn\u0027t be there.","commit_id":"7fed42089b148036c5f62e4aa4009b5a4e3dc9d7"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"96b1b25f32d642f61ba09171e9ce06b62aebcee0","unresolved":false,"context_lines":[{"line_number":153,"context_line":"                                                backup_default_container,"},{"line_number":154,"context_line":"                                                enable_progress_timer,"},{"line_number":155,"context_line":"                                                db)"},{"line_number":156,"context_line":"        # added to prevent errors"},{"line_number":157,"context_line":"        if context:"},{"line_number":158,"context_line":"            self.initialize()"},{"line_number":159,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"ff346bd7_41d12ecd","line":156,"range":{"start_line":156,"start_character":10,"end_line":156,"end_character":33},"in_reply_to":"ff346bd7_41280e33","updated":"2017-07-25 12:30:20.000000000","message":"Done","commit_id":"7fed42089b148036c5f62e4aa4009b5a4e3dc9d7"},{"author":{"_account_id":1207,"name":"Duncan Thomas","email":"duncan.thomas@gmail.com","username":"duncan-thomas"},"change_message_id":"2892daabb8cc456b93c3e631f991b75dd29c8107","unresolved":false,"context_lines":[{"line_number":379,"context_line":"        # After just trying to do easiest operations, that will show"},{"line_number":380,"context_line":"        # that we\u0027ve configured swift backup driver in right way"},{"line_number":381,"context_line":"        if not CONF.backup_swift_url:"},{"line_number":382,"context_line":"            LOG.warning(\"We will use endpoints from keystone. Possible, \""},{"line_number":383,"context_line":"                        \"we could have problems because of it.\")"},{"line_number":384,"context_line":"            return"},{"line_number":385,"context_line":"        conn \u003d swift.Connection(retries\u003dCONF.backup_swift_retry_attempts,"}],"source_content_type":"text/x-python","patch_set":16,"id":"ff346bd7_a1169af0","line":382,"range":{"start_line":382,"start_character":62,"end_line":382,"end_character":70},"updated":"2017-07-25 12:18:55.000000000","message":"Grammar nit: Should \"Possibly, we could\" or \"It is possible we could\"","commit_id":"7fed42089b148036c5f62e4aa4009b5a4e3dc9d7"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"96b1b25f32d642f61ba09171e9ce06b62aebcee0","unresolved":false,"context_lines":[{"line_number":379,"context_line":"        # After just trying to do easiest operations, that will show"},{"line_number":380,"context_line":"        # that we\u0027ve configured swift backup driver in right way"},{"line_number":381,"context_line":"        if not CONF.backup_swift_url:"},{"line_number":382,"context_line":"            LOG.warning(\"We will use endpoints from keystone. Possible, \""},{"line_number":383,"context_line":"                        \"we could have problems because of it.\")"},{"line_number":384,"context_line":"            return"},{"line_number":385,"context_line":"        conn \u003d swift.Connection(retries\u003dCONF.backup_swift_retry_attempts,"}],"source_content_type":"text/x-python","patch_set":16,"id":"ff346bd7_21ed0a8b","line":382,"range":{"start_line":382,"start_character":62,"end_line":382,"end_character":70},"in_reply_to":"ff346bd7_a1169af0","updated":"2017-07-25 12:30:20.000000000","message":"Thanks","commit_id":"7fed42089b148036c5f62e4aa4009b5a4e3dc9d7"}],"cinder/backup/manager.py":[{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"2d5f90ab491261d7f3b0a04584d8d6ebb0c99768","unresolved":false,"context_lines":[{"line_number":988,"context_line":"                context, attach_info, device, properties, force)"},{"line_number":989,"context_line":""},{"line_number":990,"context_line":"    def is_working(self):"},{"line_number":991,"context_line":"        return self.is_initialized"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_17d124fc","line":991,"range":{"start_line":991,"start_character":15,"end_line":991,"end_character":34},"updated":"2017-03-16 17:40:55.000000000","message":"Is this updated in places other than init_host()?","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":23602,"name":"Michael Dovgal","email":"dovgalmichael@gmail.com","username":"mdovgal"},"change_message_id":"c1c756dc6b3b02654a2b998d01f7a798c12e49a3","unresolved":false,"context_lines":[{"line_number":988,"context_line":"                context, attach_info, device, properties, force)"},{"line_number":989,"context_line":""},{"line_number":990,"context_line":"    def is_working(self):"},{"line_number":991,"context_line":"        return self.is_initialized"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a1ced50_766251da","line":991,"range":{"start_line":991,"start_character":15,"end_line":991,"end_character":34},"in_reply_to":"1a1ced50_17d124fc","updated":"2017-03-16 22:47:55.000000000","message":"Now I want to set it only in init_host method like for c-vol service. For c-vol we have the same idea - the service.is_working method returns driver.initialized value.\n\nAs for c-bak service at every operation like create/delete backup we create new instance of backup driver object I decided to save this flag in backup manager object.\n\nBut something can change a little if we will add re-init as is described here https://review.openstack.org/#/c/367439/5/specs/pike/backup-init.rst@45","commit_id":"62b6161ae27db1e9d44521dd2315ac2d59815cd7"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"9ea761679b84531e1e8fa423131d7748cc3cec8b","unresolved":false,"context_lines":[{"line_number":110,"context_line":"        return service"},{"line_number":111,"context_line":""},{"line_number":112,"context_line":"    def _update_backup_error(self, backup, err,"},{"line_number":113,"context_line":"                             status \u003d fields.BackupStatus.ERROR):"},{"line_number":114,"context_line":"        backup.status \u003d status"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"        backup.fail_reason \u003d err"}],"source_content_type":"text/x-python","patch_set":5,"id":"7f231b9d_b501d73a","line":113,"range":{"start_line":113,"start_character":35,"end_line":113,"end_character":38},"updated":"2017-06-16 12:50:34.000000000","message":"Shouldn\u0027t have spaces around the \u003d","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":4523,"name":"Eric Harney","email":"eharney@redhat.com","username":"eharney"},"change_message_id":"fd69ed3a0531fc46403084a22fc4d5cf88f51f8f","unresolved":false,"context_lines":[{"line_number":935,"context_line":"                                                 properties, force\u003dforce)"},{"line_number":936,"context_line":"            rpcapi.remove_export_snapshot(ctxt, device)"},{"line_number":937,"context_line":""},{"line_number":938,"context_line":"    def is_working(self):"},{"line_number":939,"context_line":"        return self.is_initialized"},{"line_number":940,"context_line":""},{"line_number":941,"context_line":"    @periodic_task.periodic_task(spacing\u003d10)"}],"source_content_type":"text/x-python","patch_set":5,"id":"7f231b9d_b839ced7","line":938,"range":{"start_line":938,"start_character":8,"end_line":938,"end_character":9},"updated":"2017-06-16 13:03:13.000000000","message":"I think \"is_initialized\" is a much better name -- \"is working\" has a lot of more vague implications, \"is initialized\" is clear about what is being validated.","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":23602,"name":"Michael Dovgal","email":"dovgalmichael@gmail.com","username":"mdovgal"},"change_message_id":"d8b3ab3a4124d8ce15fc462273bca93a54ec874f","unresolved":false,"context_lines":[{"line_number":935,"context_line":"                                                 properties, force\u003dforce)"},{"line_number":936,"context_line":"            rpcapi.remove_export_snapshot(ctxt, device)"},{"line_number":937,"context_line":""},{"line_number":938,"context_line":"    def is_working(self):"},{"line_number":939,"context_line":"        return self.is_initialized"},{"line_number":940,"context_line":""},{"line_number":941,"context_line":"    @periodic_task.periodic_task(spacing\u003d10)"}],"source_content_type":"text/x-python","patch_set":5,"id":"7f231b9d_6b2fde87","line":938,"range":{"start_line":938,"start_character":8,"end_line":938,"end_character":9},"in_reply_to":"7f231b9d_b839ced7","updated":"2017-06-16 13:48:20.000000000","message":"the idea was the same as here https://github.com/openstack/cinder/blob/18744ba1991a7e1599d256857727454bac1ae2d2/cinder/volume/manager.py#L579-L586\nBut due to we don\u0027t have single backup driver class instance, here the logic a little bit different","commit_id":"ab0df1b2589e861151b2778725cecccf3f3ef595"},{"author":{"_account_id":23083,"name":"TommyLike","email":"tommylikehu@gmail.com","username":"TommyLike"},"change_message_id":"b7bd548b86cf5dc751d3e1f083fa8c4d0b87ac46","unresolved":false,"context_lines":[{"line_number":941,"context_line":"                                                 properties, force\u003dforce)"},{"line_number":942,"context_line":"            rpcapi.remove_export_snapshot(ctxt, device)"},{"line_number":943,"context_line":""},{"line_number":944,"context_line":"    def is_working(self):"},{"line_number":945,"context_line":"        return self.is_initialized"},{"line_number":946,"context_line":""},{"line_number":947,"context_line":"    @periodic_task.periodic_task(spacing\u003dCONF.periodic_interval)"},{"line_number":948,"context_line":"    def _report_driver_status(self, context):"}],"source_content_type":"text/x-python","patch_set":12,"id":"1f1a1f67_776ee82f","line":945,"range":{"start_line":944,"start_character":4,"end_line":945,"end_character":34},"updated":"2017-07-17 01:48:23.000000000","message":"How about use @property here?","commit_id":"db65cd6127aa025356f3e3a09d54a443f242300c"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"ece82d97f60beede3334aa7514560da6eb2d5e22","unresolved":false,"context_lines":[{"line_number":941,"context_line":"                                                 properties, force\u003dforce)"},{"line_number":942,"context_line":"            rpcapi.remove_export_snapshot(ctxt, device)"},{"line_number":943,"context_line":""},{"line_number":944,"context_line":"    def is_working(self):"},{"line_number":945,"context_line":"        return self.is_initialized"},{"line_number":946,"context_line":""},{"line_number":947,"context_line":"    @periodic_task.periodic_task(spacing\u003dCONF.periodic_interval)"},{"line_number":948,"context_line":"    def _report_driver_status(self, context):"}],"source_content_type":"text/x-python","patch_set":12,"id":"ff346bd7_87005169","line":945,"range":{"start_line":944,"start_character":4,"end_line":945,"end_character":34},"in_reply_to":"1f1a1f67_776ee82f","updated":"2017-07-25 07:58:55.000000000","message":"Good catch, thanks!","commit_id":"db65cd6127aa025356f3e3a09d54a443f242300c"},{"author":{"_account_id":1736,"name":"Ivan Kolodyazhny","email":"e0ne@e0ne.info","username":"e0ne"},"change_message_id":"58e0c093f954333cc7bde6716bc6fd5b637ecaa4","unresolved":false,"context_lines":[{"line_number":941,"context_line":"                                                 properties, force\u003dforce)"},{"line_number":942,"context_line":"            rpcapi.remove_export_snapshot(ctxt, device)"},{"line_number":943,"context_line":""},{"line_number":944,"context_line":"    def is_working(self):"},{"line_number":945,"context_line":"        return self.is_initialized"},{"line_number":946,"context_line":""},{"line_number":947,"context_line":"    @periodic_task.periodic_task(spacing\u003dCONF.periodic_interval)"}],"source_content_type":"text/x-python","patch_set":14,"id":"ff346bd7_7bbbc871","line":944,"updated":"2017-07-25 09:44:44.000000000","message":"@TommyLike,\n\nIt\u0027s a good idea to use property here. But we need to change it in a base manager [1] too. It\u0027s not related to this patch, so I\u0027ll do it in a following one\n\n[1] https://github.com/openstack/cinder/blob/master/cinder/manager.py#L126","commit_id":"6ca53892a00a0c541bd5c92e2771c33628f208c5"}]}
