)]}'
{"karbor/services/protection/protection_plugins/volume/cinder_protection_plugin.py":[{"author":{"_account_id":23068,"name":"Wang Hui","email":"wanghui71@huawei.com","username":"krejwang"},"change_message_id":"6f033ed2f2dbe1a954eb35b9b100b6c5bba02c38","unresolved":false,"context_lines":[{"line_number":16,"context_line":"import six"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from karbor.common import constants"},{"line_number":19,"context_line":"from karbor import exception as exc"},{"line_number":20,"context_line":"from karbor.i18n import _, _LI"},{"line_number":21,"context_line":"from karbor.services.protection import client_factory"},{"line_number":22,"context_line":"from karbor.services.protection import protection_plugin"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a89bdaa_93aef5e5","line":19,"range":{"start_line":19,"start_character":29,"end_line":19,"end_character":35},"updated":"2016-09-09 09:07:51.000000000","message":"I don\u0027t think it\u0027s necessary.","commit_id":"bb7ca47c109f42dbb41068e3665a9a442a7f5ab5"},{"author":{"_account_id":18266,"name":"zengchen","email":"chenzeng2@huawei.com","username":"zengchen"},"change_message_id":"2930e26d7ab992a48b93d005d8ac405c2da22189","unresolved":false,"context_lines":[{"line_number":126,"context_line":"                resource_section.update_object("},{"line_number":127,"context_line":"                    \u0027status\u0027, constants.RESOURCE_STATUS_AVAILABLE)"},{"line_number":128,"context_line":"                return"},{"line_number":129,"context_line":"            elif backup.status \u003d\u003d CINDER_STATUS_CREATING:"},{"line_number":130,"context_line":"                yield"},{"line_number":131,"context_line":"            else:"},{"line_number":132,"context_line":"                if backup.status \u003d\u003d CINDER_STATUS_ERROR:"},{"line_number":133,"context_line":"                    reason \u003d backup.fail_reason"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a89bdaa_d21085ae","line":130,"range":{"start_line":129,"start_character":0,"end_line":130,"end_character":21},"updated":"2016-09-09 03:39:11.000000000","message":"It would be better move these two statements to the end. Because if do as present, when waked up, the codes will go to check the old backup.status which is not very reasonable. If moving them to the end, then it will check the new status each time.","commit_id":"bb7ca47c109f42dbb41068e3665a9a442a7f5ab5"},{"author":{"_account_id":15069,"name":"zhonghuali","email":"lizhonghua.li@huawei.com","username":"sloblee"},"change_message_id":"199b6a4c9db0f337667127e64842230bb8b57aab","unresolved":false,"context_lines":[{"line_number":142,"context_line":"                    resource_type\u003dresource.type,"},{"line_number":143,"context_line":"                    reason\u003dreason)"},{"line_number":144,"context_line":""},{"line_number":145,"context_line":"    def activity_delete_parallel(self, checkpoint, resource, context,"},{"line_number":146,"context_line":"                                 parameters):"},{"line_number":147,"context_line":"        resource_section \u003d checkpoint.get_resource_bank_section(resource.id)"},{"line_number":148,"context_line":"        resource_section.update_object(\u0027status\u0027,"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a89bdaa_7c0659cf","line":145,"range":{"start_line":145,"start_character":8,"end_line":145,"end_character":32},"updated":"2016-09-06 12:34:12.000000000","message":"also about the method name, it\u0027s a little unreadable.see another comment here:\nhttps://review.openstack.org/#/c/348163/10/karbor/services/protection/resource_flow.py\nI have a suggestion about this: either to add a \"BaseProtectionPlugin\" which can abstract to more readable or to change the rule of method name in \"protection_plugin\" class.could you please think it over?","commit_id":"bb7ca47c109f42dbb41068e3665a9a442a7f5ab5"},{"author":{"_account_id":18266,"name":"zengchen","email":"chenzeng2@huawei.com","username":"zengchen"},"change_message_id":"2930e26d7ab992a48b93d005d8ac405c2da22189","unresolved":false,"context_lines":[{"line_number":171,"context_line":"            LOG.info(_LI(\u0027Cinder Backup Delete: backup id: %(id)s \u0027"},{"line_number":172,"context_line":"                         \u0027status: %(status)s\u0027),"},{"line_number":173,"context_line":"                     {\u0027id\u0027: backup_id, \u0027status\u0027: backup.status})"},{"line_number":174,"context_line":"            if backup.status \u003d\u003d CINDER_STATUS_DELETING:"},{"line_number":175,"context_line":"                yield"},{"line_number":176,"context_line":"            else:"},{"line_number":177,"context_line":"                if backup.status \u003d\u003d CINDER_STATUS_ERROR_DELETING:"},{"line_number":178,"context_line":"                    reason \u003d backup.fail_reason"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a89bdaa_921fddb6","line":175,"range":{"start_line":174,"start_character":0,"end_line":175,"end_character":21},"updated":"2016-09-09 03:39:11.000000000","message":"ditto","commit_id":"bb7ca47c109f42dbb41068e3665a9a442a7f5ab5"}],"karbor/tests/unit/protection/test_cinder_protection_plugin.py":[{"author":{"_account_id":18266,"name":"zengchen","email":"chenzeng2@huawei.com","username":"zengchen"},"change_message_id":"2930e26d7ab992a48b93d005d8ac405c2da22189","unresolved":false,"context_lines":[{"line_number":72,"context_line":"        return self.bank_section"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"class CinderProtectionPluginTest(base.TestCase):"},{"line_number":76,"context_line":"    def setUp(self):"},{"line_number":77,"context_line":"        super(CinderProtectionPluginTest, self).setUp()"},{"line_number":78,"context_line":"        self.plugin \u003d CinderBackupProtectionPlugin()"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a89bdaa_32d531b9","line":75,"range":{"start_line":75,"start_character":6,"end_line":75,"end_character":32},"updated":"2016-09-09 03:39:11.000000000","message":"s/CinderProtectionPluginTest/CinderBackupProtectionPluginTest","commit_id":"bb7ca47c109f42dbb41068e3665a9a442a7f5ab5"},{"author":{"_account_id":18266,"name":"zengchen","email":"chenzeng2@huawei.com","username":"zengchen"},"change_message_id":"2930e26d7ab992a48b93d005d8ac405c2da22189","unresolved":false,"context_lines":[{"line_number":110,"context_line":"            \u0027OS::Cinder::Volume\u0027)"},{"line_number":111,"context_line":"        self.assertEqual(options_schema,"},{"line_number":112,"context_line":"                         cinder_schemas.SAVED_INFO_SCHEMA)"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":"    def test_get_supported_resources_types(self):"},{"line_number":115,"context_line":"        types \u003d self.plugin.get_supported_resources_types()"},{"line_number":116,"context_line":"        self.assertEqual(types,"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a89bdaa_72d7b9bf","line":113,"updated":"2016-09-09 03:39:11.000000000","message":"no need test the \u0027activity_*\u0027 methods?","commit_id":"bb7ca47c109f42dbb41068e3665a9a442a7f5ab5"}],"setup.cfg":[{"author":{"_account_id":23068,"name":"Wang Hui","email":"wanghui71@huawei.com","username":"krejwang"},"change_message_id":"9a1a321feb6001db4e32b478288855ed7c11f7a8","unresolved":false,"context_lines":[{"line_number":41,"context_line":"    sqlalchemy \u003d oslo_db.sqlalchemy.migration"},{"line_number":42,"context_line":"karbor.protections \u003d"},{"line_number":43,"context_line":"    karbor-swift-bank-plugin \u003d karbor.services.protection.bank_plugins.swift_bank_plugin:SwiftBankPlugin"},{"line_number":44,"context_line":"    karbor-volume-cinder-backup-plugin \u003d karbor.services.protection.protection_plugins.volume.cinder_protection_plugin:CinderBackupProtectionPlugin"},{"line_number":45,"context_line":"    karbor-image-protection-plugin \u003d karbor.services.protection.protection_plugins.image.image_protection_plugin:GlanceProtectionPlugin"},{"line_number":46,"context_line":"karbor.provider \u003d"},{"line_number":47,"context_line":"    provider-registry \u003d karbor.services.protection.provider:ProviderRegistry"}],"source_content_type":"text/x-ttcn-cfg","patch_set":12,"id":"9a89bdaa_93da75e8","line":44,"range":{"start_line":44,"start_character":3,"end_line":44,"end_character":147},"updated":"2016-09-09 09:15:08.000000000","message":"I wonder if you do the change to show that cinder backup is one of all cinder protection functions and we will add some other protections of cinder?","commit_id":"bb7ca47c109f42dbb41068e3665a9a442a7f5ab5"}],"smaug/services/protection/protection_plugins/volume/cinder_backup.py":[{"author":{"_account_id":17151,"name":"chenying","email":"chenyingko@gmail.com","username":"chenying"},"change_message_id":"9140efe3a2b9ed71eefbac24e19c24858238f551","unresolved":false,"context_lines":[{"line_number":132,"context_line":"                    reason \u003d _(\u0027Volume should be creating or available. The \u0027"},{"line_number":133,"context_line":"                               \u0027volume status is: %(status)s\u0027"},{"line_number":134,"context_line":"                               ) % {\u0027status\u0027: backup.status}"},{"line_number":135,"context_line":"                resource_section.update_object("},{"line_number":136,"context_line":"                    \u0027status\u0027, constants.RESOURCE_STATUS_ERROR)"},{"line_number":137,"context_line":"                raise exc.ResourceProtectFailed("},{"line_number":138,"context_line":"                    resource_id\u003dresource.id,"},{"line_number":139,"context_line":"                    resource_type\u003dresource.type,"}],"source_content_type":"text/x-python","patch_set":2,"id":"bacf61ea_6daf5c2a","line":136,"range":{"start_line":135,"start_character":0,"end_line":136,"end_character":62},"updated":"2016-08-01 11:13:53.000000000","message":"If the status of resource in resource_section is error, we need consider updating the status of checkpoint with \u0027error\u0027 too.","commit_id":"27ce73016deac0bc2bf3d53b5b431a38b04b29ce"},{"author":{"_account_id":17151,"name":"chenying","email":"chenyingko@gmail.com","username":"chenying"},"change_message_id":"9140efe3a2b9ed71eefbac24e19c24858238f551","unresolved":false,"context_lines":[{"line_number":188,"context_line":"        cc \u003d self._cinder_client(context)"},{"line_number":189,"context_line":"        metadata \u003d resource_section.get_object(\u0027metadata\u0027)"},{"line_number":190,"context_line":"        backup_id \u003d metadata[\u0027backup_id\u0027]"},{"line_number":191,"context_line":"        restore \u003d cc.restores.restore("},{"line_number":192,"context_line":"            backup_id\u003dbackup_id,"},{"line_number":193,"context_line":"            volume_id\u003dparameters.get(\u0027volume_id\u0027, None)"},{"line_number":194,"context_line":"        )"},{"line_number":195,"context_line":"        restore_id \u003d restore.id"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        while True:"}],"source_content_type":"text/x-python","patch_set":2,"id":"bacf61ea_b05087d5","line":194,"range":{"start_line":191,"start_character":0,"end_line":194,"end_character":9},"updated":"2016-08-01 11:13:53.000000000","message":"Does it mean that we restore the volumes without using heat client?","commit_id":"27ce73016deac0bc2bf3d53b5b431a38b04b29ce"},{"author":{"_account_id":17151,"name":"chenying","email":"chenyingko@gmail.com","username":"chenying"},"change_message_id":"9140efe3a2b9ed71eefbac24e19c24858238f551","unresolved":false,"context_lines":[{"line_number":195,"context_line":"        restore_id \u003d restore.id"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        while True:"},{"line_number":198,"context_line":"            try:"},{"line_number":199,"context_line":"                restore \u003d cc.volumes.get(restore_id).status"},{"line_number":200,"context_line":"            except Exception:"},{"line_number":201,"context_line":"                raise exc.ResourceRestoreFailed("}],"source_content_type":"text/x-python","patch_set":2,"id":"bacf61ea_f7831154","line":198,"range":{"start_line":198,"start_character":0,"end_line":198,"end_character":16},"updated":"2016-08-01 11:13:53.000000000","message":"Do we need add a sleep for several second here?","commit_id":"27ce73016deac0bc2bf3d53b5b431a38b04b29ce"}]}
