)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"9c5c642edf40bf409e2cbbed93e7d0911b9b8975","unresolved":false,"context_lines":[{"line_number":5,"context_line":"CommitDate: 2016-12-23 16:14:53 +0200"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Backup/Restore nova tenant"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Change-Id: Ia8e4412dfaf0c24364db692de78c27cd0e3b3c4c"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":28,"id":"da4df55a_96ebca77","line":8,"updated":"2016-12-26 14:51:18.000000000","message":"nit: partially implements tenant-backup ?","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"6a1e7d44eefc2e592a86ac5bf74b8fc4cb7829e7","unresolved":false,"context_lines":[{"line_number":5,"context_line":"CommitDate: 2016-12-23 16:14:53 +0200"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Backup/Restore nova tenant"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Change-Id: Ia8e4412dfaf0c24364db692de78c27cd0e3b3c4c"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":28,"id":"ba5201f7_e2aafd6f","line":8,"in_reply_to":"da4df55a_96ebca77","updated":"2016-12-30 11:11:13.000000000","message":"Why partially?","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"}],"freezer/common/config.py":[{"author":{"_account_id":21644,"name":"Shangzhong Zhu","email":"zhu.shangzhong@zte.com.cn","username":"shangzhong.zhu"},"change_message_id":"4d359868964e84b38baf9678f27608fa7984015f","unresolved":false,"context_lines":[{"line_number":68,"context_line":"    \u0027encrypt_pass_file\u0027: None, \u0027volume\u0027: None, \u0027proxy\u0027: None,"},{"line_number":69,"context_line":"    \u0027cinder_vol_id\u0027: \u0027\u0027, \u0027cindernative_vol_id\u0027: \u0027\u0027,"},{"line_number":70,"context_line":"    \u0027nova_inst_id\u0027: \u0027\u0027, \u0027__version__\u0027: FREEZER_VERSION,"},{"line_number":71,"context_line":"    \u0027tenant_id\u0027: None, \u0027remove_older_than\u0027: None, \u0027restore_from_date\u0027: None,"},{"line_number":72,"context_line":"    \u0027upload_limit\u0027: -1, \u0027always_level\u0027: False, \u0027version\u0027: None,"},{"line_number":73,"context_line":"    \u0027dry_run\u0027: False, \u0027lvm_snapsize\u0027: DEFAULT_LVM_SNAPSIZE,"},{"line_number":74,"context_line":"    \u0027restore_abs_path\u0027: None, \u0027log_file\u0027: None, \u0027log_level\u0027: \"info\","}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_f7a3c4fd","line":71,"range":{"start_line":71,"start_character":5,"end_line":71,"end_character":14},"updated":"2016-12-07 08:56:16.000000000","message":"Could you replace \"tenant_id\" with \"project_id\"?","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"3d98c9b3e9d57bb93a29865fdc11d318224cdaaf","unresolved":false,"context_lines":[{"line_number":68,"context_line":"    \u0027encrypt_pass_file\u0027: None, \u0027volume\u0027: None, \u0027proxy\u0027: None,"},{"line_number":69,"context_line":"    \u0027cinder_vol_id\u0027: \u0027\u0027, \u0027cindernative_vol_id\u0027: \u0027\u0027,"},{"line_number":70,"context_line":"    \u0027nova_inst_id\u0027: \u0027\u0027, \u0027__version__\u0027: FREEZER_VERSION,"},{"line_number":71,"context_line":"    \u0027tenant_id\u0027: None, \u0027remove_older_than\u0027: None, \u0027restore_from_date\u0027: None,"},{"line_number":72,"context_line":"    \u0027upload_limit\u0027: -1, \u0027always_level\u0027: False, \u0027version\u0027: None,"},{"line_number":73,"context_line":"    \u0027dry_run\u0027: False, \u0027lvm_snapsize\u0027: DEFAULT_LVM_SNAPSIZE,"},{"line_number":74,"context_line":"    \u0027restore_abs_path\u0027: None, \u0027log_file\u0027: None, \u0027log_level\u0027: \"info\","}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_c456d805","line":71,"range":{"start_line":71,"start_character":5,"end_line":71,"end_character":14},"in_reply_to":"3a71b18c_f7a3c4fd","updated":"2016-12-08 11:43:18.000000000","message":"Yes, sure","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":6508,"name":"Dmitry Stepanenko","email":"dstepanenko@mirantis.com","username":"dstepanenko"},"change_message_id":"84540805af0953903e99117da79f28ec8774a166","unresolved":false,"context_lines":[{"line_number":453,"context_line":"                     \"cindernative incremental backup instead of the default \""},{"line_number":454,"context_line":"                     \"full backup. And if True, but volume do not have a base\""},{"line_number":455,"context_line":"                     \"full backup, freezer will do a full backup first\"),"},{"line_number":456,"context_line":"    cfg.StrOpt(\u0027nova-network-id\u0027,"},{"line_number":457,"context_line":"               dest\u003d\u0027nova_network_id\u0027,"},{"line_number":458,"context_line":"               default\u003dDEFAULT_PARAMS[\u0027nova_network_id\u0027],"},{"line_number":459,"context_line":"               help\u003d\"ID of the network to attach to the restored VM. \""}],"source_content_type":"text/x-python","patch_set":24,"id":"1a6eadb0_f69091ef","line":456,"updated":"2016-12-21 11:10:48.000000000","message":"The idea of renaming nova-restore-network to nova-network-id is  good, but it\u0027s better to do it in separate patch","commit_id":"7483241f03a5a4a6384b46c1b044d0aa2c7724f3"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"fc28b5fc7a91e42ba080fdc291bcdb1bc0ffbe78","unresolved":false,"context_lines":[{"line_number":453,"context_line":"                     \"cindernative incremental backup instead of the default \""},{"line_number":454,"context_line":"                     \"full backup. And if True, but volume do not have a base\""},{"line_number":455,"context_line":"                     \"full backup, freezer will do a full backup first\"),"},{"line_number":456,"context_line":"    cfg.StrOpt(\u0027nova-network-id\u0027,"},{"line_number":457,"context_line":"               dest\u003d\u0027nova_network_id\u0027,"},{"line_number":458,"context_line":"               default\u003dDEFAULT_PARAMS[\u0027nova_network_id\u0027],"},{"line_number":459,"context_line":"               help\u003d\"ID of the network to attach to the restored VM. \""}],"source_content_type":"text/x-python","patch_set":24,"id":"1a6eadb0_81646f22","line":456,"in_reply_to":"1a6eadb0_f69091ef","updated":"2016-12-21 13:51:59.000000000","message":"But in that case we will have inconsistency between freezer-agent and freezer-web-ui https://review.openstack.org/#/c/406136/5/disaster_recovery/actions/workflows/action.py , so I\u0027ve decided not to separate this two changes.","commit_id":"7483241f03a5a4a6384b46c1b044d0aa2c7724f3"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"9c5c642edf40bf409e2cbbed93e7d0911b9b8975","unresolved":false,"context_lines":[{"line_number":453,"context_line":"                     \"cindernative incremental backup instead of the default \""},{"line_number":454,"context_line":"                     \"full backup. And if True, but volume do not have a base\""},{"line_number":455,"context_line":"                     \"full backup, freezer will do a full backup first\"),"},{"line_number":456,"context_line":"    cfg.StrOpt(\u0027nova-network-id\u0027,"},{"line_number":457,"context_line":"               dest\u003d\u0027nova_network_id\u0027,"},{"line_number":458,"context_line":"               default\u003dDEFAULT_PARAMS[\u0027nova_network_id\u0027],"},{"line_number":459,"context_line":"               help\u003d\"ID of the network to attach to the restored VM. \""}],"source_content_type":"text/x-python","patch_set":28,"id":"da4df55a_d63e3227","line":456,"updated":"2016-12-26 14:51:18.000000000","message":"(optional) nit: this seems to be an unrelated change, that might affect backward compatibility (not sure if we care at this point)","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"e2754677b96aea2286b3141db7fff734ee066b0c","unresolved":false,"context_lines":[{"line_number":453,"context_line":"                     \"cindernative incremental backup instead of the default \""},{"line_number":454,"context_line":"                     \"full backup. And if True, but volume do not have a base\""},{"line_number":455,"context_line":"                     \"full backup, freezer will do a full backup first\"),"},{"line_number":456,"context_line":"    cfg.StrOpt(\u0027nova-network-id\u0027,"},{"line_number":457,"context_line":"               dest\u003d\u0027nova_network_id\u0027,"},{"line_number":458,"context_line":"               default\u003dDEFAULT_PARAMS[\u0027nova_network_id\u0027],"},{"line_number":459,"context_line":"               help\u003d\"ID of the network to attach to the restored VM. \""}],"source_content_type":"text/x-python","patch_set":31,"id":"ba5201f7_1361b539","line":456,"updated":"2017-01-04 17:04:17.000000000","message":"nit: I suggest you keep the name as is for the sake of backwards compatibility, unless there is a specific reason to change it here","commit_id":"d0ecb86c31d967f6ca361e5ad787e80582eb6d7d"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"6300d4407aad6e4c8550453af7bf908388ac3179","unresolved":false,"context_lines":[{"line_number":453,"context_line":"                     \"cindernative incremental backup instead of the default \""},{"line_number":454,"context_line":"                     \"full backup. And if True, but volume do not have a base\""},{"line_number":455,"context_line":"                     \"full backup, freezer will do a full backup first\"),"},{"line_number":456,"context_line":"    cfg.StrOpt(\u0027nova-network-id\u0027,"},{"line_number":457,"context_line":"               dest\u003d\u0027nova_network_id\u0027,"},{"line_number":458,"context_line":"               default\u003dDEFAULT_PARAMS[\u0027nova_network_id\u0027],"},{"line_number":459,"context_line":"               help\u003d\"ID of the network to attach to the restored VM. \""}],"source_content_type":"text/x-python","patch_set":31,"id":"ba5201f7_10334063","line":456,"in_reply_to":"ba5201f7_1361b539","updated":"2017-01-05 14:34:12.000000000","message":"Ok, I will move it to separate patch. Anyway there should be some unification of parameter names because freezer web ui uses this naming.","commit_id":"d0ecb86c31d967f6ca361e5ad787e80582eb6d7d"},{"author":{"_account_id":13940,"name":"Saad Zaher","email":"eng.szaher@gmail.com","username":"szaher"},"change_message_id":"7b769be99ce407dae8cf71d1d2e978cc4c69b1c7","unresolved":false,"context_lines":[{"line_number":480,"context_line":"                    \"this time it will raise a TimeOut Exception. Default is\""},{"line_number":481,"context_line":"                    \" {0}\".format(DEFAULT_PARAMS[\u0027timeout\u0027])"},{"line_number":482,"context_line":"               ),"},{"line_number":483,"context_line":"    cfg.StrOpt(\u0027backup-media\u0027,"},{"line_number":484,"context_line":"               dest\u003d\u0027backup_media\u0027,"},{"line_number":485,"context_line":"               default\u003dDEFAULT_PARAMS[\u0027backup_media\u0027],"},{"line_number":486,"context_line":"               choices\u003d[\u0027fs\u0027, \u0027cinder\u0027, \u0027cindernative\u0027, \u0027nova\u0027],"}],"source_content_type":"text/x-python","patch_set":47,"id":"1a1ced50_35f4fc84","line":483,"updated":"2017-03-20 15:31:06.000000000","message":"what is the difference between this and mode ?","commit_id":"cda45b5c1d81c858669d78042f6d831052310563"}],"freezer/engine/nova/nova.py":[{"author":{"_account_id":13940,"name":"Saad Zaher","email":"eng.szaher@gmail.com","username":"szaher"},"change_message_id":"1e30a3a6434b6ec8e0d9886705208b1ddfd7655c","unresolved":false,"context_lines":[{"line_number":74,"context_line":"                     format(instance_id, self.storage.storage_path))"},{"line_number":75,"context_line":"            backup_name \u003d os.path.join(hostname_backup_name,"},{"line_number":76,"context_line":"                                       instance_id)"},{"line_number":77,"context_line":"            executor.submit("},{"line_number":78,"context_line":"                self.restore,"},{"line_number":79,"context_line":"                hostname_backup_name\u003dbackup_name,"},{"line_number":80,"context_line":"                restore_resource\u003dinstance_id,"}],"source_content_type":"text/x-python","patch_set":50,"id":"1a1ced50_80045018","line":77,"updated":"2017-03-21 19:38:52.000000000","message":"what about holding/waiting till the thread finishes it\u0027s task then return.\n\n           future \u003d executor.submit(\n                self.restore,\n                hostname_backup_name\u003dbackup_name,\n                restore_resource\u003dinstance_id,\n                overwrite\u003doverwrite,\n                recent_to_date\u003drecent_to_date)\n            while future.running():\n                time.sleep(CONF.get(\u0027timeout\u0027, 10))\n\n\nthere is a generic variable called timeout we can use it","commit_id":"51a1e73e29f46c2c6de8d60f83fb942a3aafc5a6"},{"author":{"_account_id":13940,"name":"Saad Zaher","email":"eng.szaher@gmail.com","username":"szaher"},"change_message_id":"1e30a3a6434b6ec8e0d9886705208b1ddfd7655c","unresolved":false,"context_lines":[{"line_number":155,"context_line":"            backup_name \u003d os.path.join(hostname_backup_name,"},{"line_number":156,"context_line":"                                       instance_id)"},{"line_number":157,"context_line":""},{"line_number":158,"context_line":"            executor.submit("},{"line_number":159,"context_line":"                self.backup,"},{"line_number":160,"context_line":"                backup_resource\u003dinstance_id,"},{"line_number":161,"context_line":"                hostname_backup_name\u003dbackup_name,"}],"source_content_type":"text/x-python","patch_set":50,"id":"1a1ced50_8b1b9172","line":158,"updated":"2017-03-21 19:38:52.000000000","message":"same like above ?","commit_id":"51a1e73e29f46c2c6de8d60f83fb942a3aafc5a6"}],"freezer/job.py":[{"author":{"_account_id":21644,"name":"Shangzhong Zhu","email":"zhu.shangzhong@zte.com.cn","username":"shangzhong.zhu"},"change_message_id":"4d359868964e84b38baf9678f27608fa7984015f","unresolved":false,"context_lines":[{"line_number":306,"context_line":"            network_id \u003d conf.nova_network_id"},{"line_number":307,"context_line":"            res.restore_nova_tenant(tenant_id, restore_timestamp, network_id,"},{"line_number":308,"context_line":"                                    self.conf.max_segment_size)"},{"line_number":309,"context_line":"        elif conf.backup_media \u003d\u003d \u0027nova\u0027 and conf.nova_inst_id:"},{"line_number":310,"context_line":"            LOG.info(\"Restoring nova backup. Instance ID: {0}, timestamp: {1}\""},{"line_number":311,"context_line":"                     .format(conf.nova_inst_id, restore_timestamp))"},{"line_number":312,"context_line":"            nova_network \u003d None"}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_175a00f2","line":309,"range":{"start_line":309,"start_character":8,"end_line":309,"end_character":63},"updated":"2016-12-07 08:56:16.000000000","message":"The \"conf.nova_inst_id\" should be removed.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":21644,"name":"Shangzhong Zhu","email":"zhu.shangzhong@zte.com.cn","username":"shangzhong.zhu"},"change_message_id":"3c50a0bd750140020fba4efa390beb7ddfc4d16c","unresolved":false,"context_lines":[{"line_number":306,"context_line":"            network_id \u003d conf.nova_network_id"},{"line_number":307,"context_line":"            res.restore_nova_tenant(tenant_id, restore_timestamp, network_id,"},{"line_number":308,"context_line":"                                    self.conf.max_segment_size)"},{"line_number":309,"context_line":"        elif conf.backup_media \u003d\u003d \u0027nova\u0027 and conf.nova_inst_id:"},{"line_number":310,"context_line":"            LOG.info(\"Restoring nova backup. Instance ID: {0}, timestamp: {1}\""},{"line_number":311,"context_line":"                     .format(conf.nova_inst_id, restore_timestamp))"},{"line_number":312,"context_line":"            nova_network \u003d None"}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_3728dc99","line":309,"range":{"start_line":309,"start_character":8,"end_line":309,"end_character":63},"in_reply_to":"3a71b18c_175a00f2","updated":"2016-12-07 09:01:26.000000000","message":"I make a mistake. Please ignore it.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"}],"freezer/openstack/backup.py":[{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"43b8dedc9f2a34f6651555540b49175220f3b563","unresolved":false,"context_lines":[{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def backup_nova_tenant(self, tenant_id, chunk_size):"},{"line_number":81,"context_line":"        client_manager \u003d self.client_manager"},{"line_number":82,"context_line":"        nova \u003d client_manager.get_nova()"},{"line_number":83,"context_line":"        instance_ids \u003d [server.id for server in nova.servers.list()"},{"line_number":84,"context_line":"                        if server.tenant_id \u003d\u003d tenant_id]"},{"line_number":85,"context_line":""}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_df07be15","line":82,"range":{"start_line":82,"start_character":15,"end_line":82,"end_character":40},"updated":"2016-12-07 09:58:34.000000000","message":"I\u0027m not sure how the client instance is created and what credentials (admin or the tenant we are trying to backup) are used, but at the very least we need to make sure that filtering by tenant_id is performed on the server side (with a regular tenant credentials you can only see \"your\" instances, so filtering is performed automatically )","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"3d98c9b3e9d57bb93a29865fdc11d318224cdaaf","unresolved":false,"context_lines":[{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def backup_nova_tenant(self, tenant_id, chunk_size):"},{"line_number":81,"context_line":"        client_manager \u003d self.client_manager"},{"line_number":82,"context_line":"        nova \u003d client_manager.get_nova()"},{"line_number":83,"context_line":"        instance_ids \u003d [server.id for server in nova.servers.list()"},{"line_number":84,"context_line":"                        if server.tenant_id \u003d\u003d tenant_id]"},{"line_number":85,"context_line":""}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_6446e4c0","line":82,"range":{"start_line":82,"start_character":15,"end_line":82,"end_character":40},"in_reply_to":"3a71b18c_df07be15","updated":"2016-12-08 11:43:18.000000000","message":"Yes, but I thought admin user is able to see other tenants instances and backup them too.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"43b8dedc9f2a34f6651555540b49175220f3b563","unresolved":false,"context_lines":[{"line_number":94,"context_line":"        headers, body \u003d swift_connection.get_object(tenant_id,"},{"line_number":95,"context_line":"                                                    tenant_id,"},{"line_number":96,"context_line":"                                                    chunk_size)"},{"line_number":97,"context_line":"        instance_ids \u003d json.loads(body.read())"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"        for instance_id in instance_ids:"},{"line_number":100,"context_line":"            container_id \u003d \"{0}_{1}\".format(tenant_id, instance_id)"}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_9f84665e","line":97,"updated":"2016-12-07 09:58:34.000000000","message":"As you already have these IDs why load the from Swift? Is that a sanity check?","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"a5bf74350a65bf36dbc181f7d439a45e52ead5f1","unresolved":false,"context_lines":[{"line_number":94,"context_line":"        headers, body \u003d swift_connection.get_object(tenant_id,"},{"line_number":95,"context_line":"                                                    tenant_id,"},{"line_number":96,"context_line":"                                                    chunk_size)"},{"line_number":97,"context_line":"        instance_ids \u003d json.loads(body.read())"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"        for instance_id in instance_ids:"},{"line_number":100,"context_line":"            container_id \u003d \"{0}_{1}\".format(tenant_id, instance_id)"}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_5f8d317a","line":97,"in_reply_to":"3a71b18c_9f84665e","updated":"2016-12-08 11:49:22.000000000","message":"Oh, thanks. This is not sanity check. I\u0027ve experimented with that and I\u0027ve forgot to remove it.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":21224,"name":"jiaopengju","email":"jiaopengju_yewu@cmss.chinamobile.com","username":"jiaopengju"},"change_message_id":"77976c9072424e87530283e8a2715b1a6063eabc","unresolved":false,"context_lines":[{"line_number":99,"context_line":"        for instance_id in instance_ids:"},{"line_number":100,"context_line":"            container_id \u003d \"{0}_{1}\".format(tenant_id, instance_id)"},{"line_number":101,"context_line":"            # Create new storage per instance"},{"line_number":102,"context_line":"            self.storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":103,"context_line":"                                              container_id,"},{"line_number":104,"context_line":"                                              chunk_size)"},{"line_number":105,"context_line":"            LOG.info(\"Backup nova instance Id: {0} to container {1}\"."}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_ebbe8e63","line":102,"range":{"start_line":102,"start_character":27,"end_line":102,"end_character":46},"updated":"2016-12-07 02:12:58.000000000","message":"I would use self.storage instead of swift.SwiftStorage here, or add a function such as \u0027clone\u0027 in self.storage to create new storage per instance. \nAt the same time, these swift requests are sequential  and synchronous, so per instance with a new storage will be ineffective except using parallel backup.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":21224,"name":"jiaopengju","email":"jiaopengju_yewu@cmss.chinamobile.com","username":"jiaopengju"},"change_message_id":"12d9bdba2bafcc44cd8f5601f0b74c83d6a9a59b","unresolved":false,"context_lines":[{"line_number":99,"context_line":"        for instance_id in instance_ids:"},{"line_number":100,"context_line":"            container_id \u003d \"{0}_{1}\".format(tenant_id, instance_id)"},{"line_number":101,"context_line":"            # Create new storage per instance"},{"line_number":102,"context_line":"            self.storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":103,"context_line":"                                              container_id,"},{"line_number":104,"context_line":"                                              chunk_size)"},{"line_number":105,"context_line":"            LOG.info(\"Backup nova instance Id: {0} to container {1}\"."}],"source_content_type":"text/x-python","patch_set":17,"id":"1a6eadb0_fb007aad","line":102,"range":{"start_line":102,"start_character":27,"end_line":102,"end_character":46},"in_reply_to":"1a6eadb0_00aa8b70","updated":"2016-12-21 09:57:04.000000000","message":"I had mean to add a method in SwiftStorage such as \u0027load(container)\u0027 or any other method name to change the target to a different container, if so  we should not assign value to self.storage in the loop with using class \u0027SwiftStorage\u0027 here. I don\u0027t know if it will be better and this is for your reference only.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"c7e9ac6fbe8810505d84abeba79ae6c18053801f","unresolved":false,"context_lines":[{"line_number":99,"context_line":"        for instance_id in instance_ids:"},{"line_number":100,"context_line":"            container_id \u003d \"{0}_{1}\".format(tenant_id, instance_id)"},{"line_number":101,"context_line":"            # Create new storage per instance"},{"line_number":102,"context_line":"            self.storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":103,"context_line":"                                              container_id,"},{"line_number":104,"context_line":"                                              chunk_size)"},{"line_number":105,"context_line":"            LOG.info(\"Backup nova instance Id: {0} to container {1}\"."}],"source_content_type":"text/x-python","patch_set":17,"id":"1a6eadb0_00aa8b70","line":102,"range":{"start_line":102,"start_character":27,"end_line":102,"end_character":46},"in_reply_to":"1a6eadb0_ba5d894a","updated":"2016-12-19 14:16:28.000000000","message":"I understand that you want to do with decoupling. But I am not sure about your proposal. How exactly add this function with container argument?","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":21224,"name":"jiaopengju","email":"jiaopengju_yewu@cmss.chinamobile.com","username":"jiaopengju"},"change_message_id":"12d9bdba2bafcc44cd8f5601f0b74c83d6a9a59b","unresolved":false,"context_lines":[{"line_number":99,"context_line":"        for instance_id in instance_ids:"},{"line_number":100,"context_line":"            container_id \u003d \"{0}_{1}\".format(tenant_id, instance_id)"},{"line_number":101,"context_line":"            # Create new storage per instance"},{"line_number":102,"context_line":"            self.storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":103,"context_line":"                                              container_id,"},{"line_number":104,"context_line":"                                              chunk_size)"},{"line_number":105,"context_line":"            LOG.info(\"Backup nova instance Id: {0} to container {1}\"."}],"source_content_type":"text/x-python","patch_set":17,"id":"1a6eadb0_8080f7c0","line":102,"range":{"start_line":102,"start_character":27,"end_line":102,"end_character":46},"in_reply_to":"1a6eadb0_ba5d894a","updated":"2016-12-21 09:57:04.000000000","message":"That sounds right.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":21224,"name":"jiaopengju","email":"jiaopengju_yewu@cmss.chinamobile.com","username":"jiaopengju"},"change_message_id":"b8a1c36721a57094e6f40bb1eb11b247711e2862","unresolved":false,"context_lines":[{"line_number":99,"context_line":"        for instance_id in instance_ids:"},{"line_number":100,"context_line":"            container_id \u003d \"{0}_{1}\".format(tenant_id, instance_id)"},{"line_number":101,"context_line":"            # Create new storage per instance"},{"line_number":102,"context_line":"            self.storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":103,"context_line":"                                              container_id,"},{"line_number":104,"context_line":"                                              chunk_size)"},{"line_number":105,"context_line":"            LOG.info(\"Backup nova instance Id: {0} to container {1}\"."}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_b5d28ffe","line":102,"range":{"start_line":102,"start_character":27,"end_line":102,"end_character":46},"in_reply_to":"3a71b18c_442f28a1","updated":"2016-12-10 07:10:52.000000000","message":"This will make the two parts(backup and the backend storage) tightly coupled. I think you can add a function in self.storage with using  container name as a argument.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"b43c1abfc5155aab6dc362bd5c22b0d862f66b82","unresolved":false,"context_lines":[{"line_number":99,"context_line":"        for instance_id in instance_ids:"},{"line_number":100,"context_line":"            container_id \u003d \"{0}_{1}\".format(tenant_id, instance_id)"},{"line_number":101,"context_line":"            # Create new storage per instance"},{"line_number":102,"context_line":"            self.storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":103,"context_line":"                                              container_id,"},{"line_number":104,"context_line":"                                              chunk_size)"},{"line_number":105,"context_line":"            LOG.info(\"Backup nova instance Id: {0} to container {1}\"."}],"source_content_type":"text/x-python","patch_set":17,"id":"1a6eadb0_ba5d894a","line":102,"range":{"start_line":102,"start_character":27,"end_line":102,"end_character":46},"in_reply_to":"3a71b18c_b5d28ffe","updated":"2016-12-19 13:56:12.000000000","message":"But now nova backup is already tightly coupled as far as nova can backup to swift only.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"3d98c9b3e9d57bb93a29865fdc11d318224cdaaf","unresolved":false,"context_lines":[{"line_number":99,"context_line":"        for instance_id in instance_ids:"},{"line_number":100,"context_line":"            container_id \u003d \"{0}_{1}\".format(tenant_id, instance_id)"},{"line_number":101,"context_line":"            # Create new storage per instance"},{"line_number":102,"context_line":"            self.storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":103,"context_line":"                                              container_id,"},{"line_number":104,"context_line":"                                              chunk_size)"},{"line_number":105,"context_line":"            LOG.info(\"Backup nova instance Id: {0} to container {1}\"."}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_442f28a1","line":102,"range":{"start_line":102,"start_character":27,"end_line":102,"end_character":46},"in_reply_to":"3a71b18c_ebbe8e63","updated":"2016-12-08 11:43:18.000000000","message":"swift storage is tightly coupled to specific container, so if I use self.storage - I will write all of the backups to the same container and overwrite older. Yeah, it looks clumsy. But when we call self.backup_nova - that self.storage is used, so we need to override it too. So namely self.storage of BackupJob shold be changed.\n    I\u0027ve write to do note below to wrap each backup operation in thread/greenthread for the sake of parallelism.","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"43b8dedc9f2a34f6651555540b49175220f3b563","unresolved":false,"context_lines":[{"line_number":104,"context_line":"                                              chunk_size)"},{"line_number":105,"context_line":"            LOG.info(\"Backup nova instance Id: {0} to container {1}\"."},{"line_number":106,"context_line":"                     format(instance_id, container_id))"},{"line_number":107,"context_line":"            # TODO(gstepanov): Consider using Thread pool for parallel backup"},{"line_number":108,"context_line":"            self.backup_nova(instance_id)"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    def backup_cinder_by_glance(self, volume_id):"}],"source_content_type":"text/x-python","patch_set":17,"id":"3a71b18c_5f61eed1","line":107,"updated":"2016-12-07 09:58:34.000000000","message":"Agreed, this may be done in a separate commit. I suggest you look at something like https://github.com/openstack/futurist/blob/master/futurist/_futures.py#L321","commit_id":"a6b24ef937e614b8c7365b997dfd2559e9da03e2"},{"author":{"_account_id":6508,"name":"Dmitry Stepanenko","email":"dstepanenko@mirantis.com","username":"dstepanenko"},"change_message_id":"84540805af0953903e99117da79f28ec8774a166","unresolved":false,"context_lines":[{"line_number":84,"context_line":"        instance_ids \u003d [server.id for server in nova.servers.list()]"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"        # Save info about tenant instances in swift"},{"line_number":87,"context_line":"        storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":88,"context_line":"                                     project_id,"},{"line_number":89,"context_line":"                                     chunk_size)"},{"line_number":90,"context_line":"        swift_connection \u003d storage.client_manager.create_swift()"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a6eadb0_95b11204","line":87,"updated":"2016-12-21 11:10:48.000000000","message":"You can use self.storage here instead of instantiating a class SwiftStorage. If you pass all parameters in a proper way, it should contain instance of SwiftStorage class.","commit_id":"7483241f03a5a4a6384b46c1b044d0aa2c7724f3"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"fc28b5fc7a91e42ba080fdc291bcdb1bc0ffbe78","unresolved":false,"context_lines":[{"line_number":84,"context_line":"        instance_ids \u003d [server.id for server in nova.servers.list()]"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"        # Save info about tenant instances in swift"},{"line_number":87,"context_line":"        storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":88,"context_line":"                                     project_id,"},{"line_number":89,"context_line":"                                     chunk_size)"},{"line_number":90,"context_line":"        swift_connection \u003d storage.client_manager.create_swift()"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a6eadb0_e13d23de","line":87,"in_reply_to":"1a6eadb0_95b11204","updated":"2016-12-21 13:51:59.000000000","message":"I\u0027ll look on that","commit_id":"7483241f03a5a4a6384b46c1b044d0aa2c7724f3"},{"author":{"_account_id":6508,"name":"Dmitry Stepanenko","email":"dstepanenko@mirantis.com","username":"dstepanenko"},"change_message_id":"84540805af0953903e99117da79f28ec8774a166","unresolved":false,"context_lines":[{"line_number":89,"context_line":"                                     chunk_size)"},{"line_number":90,"context_line":"        swift_connection \u003d storage.client_manager.create_swift()"},{"line_number":91,"context_line":"        data \u003d json.dumps(instance_ids)"},{"line_number":92,"context_line":"        LOG.info(\"Save information about instances {0}\".format(data))"},{"line_number":93,"context_line":"        swift_connection.put_object(project_id, project_id, data)"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        for instance_id in instance_ids:"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a6eadb0_76b3a19a","line":92,"updated":"2016-12-21 11:10:48.000000000","message":"Save -\u003e Saving","commit_id":"7483241f03a5a4a6384b46c1b044d0aa2c7724f3"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"fc28b5fc7a91e42ba080fdc291bcdb1bc0ffbe78","unresolved":false,"context_lines":[{"line_number":89,"context_line":"                                     chunk_size)"},{"line_number":90,"context_line":"        swift_connection \u003d storage.client_manager.create_swift()"},{"line_number":91,"context_line":"        data \u003d json.dumps(instance_ids)"},{"line_number":92,"context_line":"        LOG.info(\"Save information about instances {0}\".format(data))"},{"line_number":93,"context_line":"        swift_connection.put_object(project_id, project_id, data)"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        for instance_id in instance_ids:"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a6eadb0_617cb3b5","line":92,"in_reply_to":"1a6eadb0_76b3a19a","updated":"2016-12-21 13:51:59.000000000","message":"Ok","commit_id":"7483241f03a5a4a6384b46c1b044d0aa2c7724f3"},{"author":{"_account_id":6508,"name":"Dmitry Stepanenko","email":"dstepanenko@mirantis.com","username":"dstepanenko"},"change_message_id":"d88a804a758add3d9fcf427acd52e585c9b3f48c","unresolved":false,"context_lines":[{"line_number":87,"context_line":"        storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":88,"context_line":"                                     project_id,"},{"line_number":89,"context_line":"                                     chunk_size)"},{"line_number":90,"context_line":"        swift_connection \u003d storage.client_managtest_er.create_swift()"},{"line_number":91,"context_line":"        data \u003d json.dumps(instance_ids)"},{"line_number":92,"context_line":"        LOG.info(\"Saving information about instances {0}\".format(data))"},{"line_number":93,"context_line":"        swift_connection.put_object(project_id, project_id, data)"}],"source_content_type":"text/x-python","patch_set":25,"id":"1a6eadb0_378e7979","line":90,"updated":"2016-12-21 14:15:38.000000000","message":"Please be carefull. It seems that this is typo","commit_id":"f0f2add8e5f18cc60d2896774fed68bf1ed766a9"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"9c5c642edf40bf409e2cbbed93e7d0911b9b8975","unresolved":false,"context_lines":[{"line_number":81,"context_line":"    def backup_nova_tenant(self, project_id, chunk_size):"},{"line_number":82,"context_line":"        client_manager \u003d self.client_manager"},{"line_number":83,"context_line":"        nova \u003d client_manager.get_nova()"},{"line_number":84,"context_line":"        instance_ids \u003d [server.id for server in nova.servers.list()]"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"        # Save info about tenant instances in swift"},{"line_number":87,"context_line":"        swift_connection \u003d self.storage.client_manager.create_swift()"}],"source_content_type":"text/x-python","patch_set":28,"id":"da4df55a_768106c3","line":84,"range":{"start_line":84,"start_character":48,"end_line":84,"end_character":67},"updated":"2016-12-26 14:51:18.000000000","message":"nit: list() returns detailed info by default. As you are only interested in IDs here, you could pass detailed\u003dFalse to transfer less data\n\n(https://github.com/openstack/python-novaclient/blob/master/novaclient/v2/servers.py#L764)","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"6a1e7d44eefc2e592a86ac5bf74b8fc4cb7829e7","unresolved":false,"context_lines":[{"line_number":81,"context_line":"    def backup_nova_tenant(self, project_id, chunk_size):"},{"line_number":82,"context_line":"        client_manager \u003d self.client_manager"},{"line_number":83,"context_line":"        nova \u003d client_manager.get_nova()"},{"line_number":84,"context_line":"        instance_ids \u003d [server.id for server in nova.servers.list()]"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"        # Save info about tenant instances in swift"},{"line_number":87,"context_line":"        swift_connection \u003d self.storage.client_manager.create_swift()"}],"source_content_type":"text/x-python","patch_set":28,"id":"ba5201f7_62b52dcc","line":84,"range":{"start_line":84,"start_character":48,"end_line":84,"end_character":67},"in_reply_to":"da4df55a_768106c3","updated":"2016-12-30 11:11:13.000000000","message":"Thanks, good tip","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"9c5c642edf40bf409e2cbbed93e7d0911b9b8975","unresolved":false,"context_lines":[{"line_number":87,"context_line":"        swift_connection \u003d self.storage.client_manager.create_swift()"},{"line_number":88,"context_line":"        data \u003d json.dumps(instance_ids)"},{"line_number":89,"context_line":"        LOG.info(\"Saving information about instances {0}\".format(data))"},{"line_number":90,"context_line":"        swift_connection.put_object(project_id, project_id, data)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"        for instance_id in instance_ids:"},{"line_number":93,"context_line":"            container_id \u003d \"{0}_{1}\".format(project_id, instance_id)"}],"source_content_type":"text/x-python","patch_set":28,"id":"da4df55a_56c322ed","line":90,"updated":"2016-12-26 14:51:18.000000000","message":"Perhaps we should a different object name? (as project_id might as well be used for backing up e.g. cinder volumes in the future) Make it clear it\u0027s nova-specific?","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"6a1e7d44eefc2e592a86ac5bf74b8fc4cb7829e7","unresolved":false,"context_lines":[{"line_number":87,"context_line":"        swift_connection \u003d self.storage.client_manager.create_swift()"},{"line_number":88,"context_line":"        data \u003d json.dumps(instance_ids)"},{"line_number":89,"context_line":"        LOG.info(\"Saving information about instances {0}\".format(data))"},{"line_number":90,"context_line":"        swift_connection.put_object(project_id, project_id, data)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"        for instance_id in instance_ids:"},{"line_number":93,"context_line":"            container_id \u003d \"{0}_{1}\".format(project_id, instance_id)"}],"source_content_type":"text/x-python","patch_set":28,"id":"ba5201f7_a2c71544","line":90,"in_reply_to":"da4df55a_56c322ed","updated":"2016-12-30 11:11:13.000000000","message":"So, call it nova_project_id? I cant\u0027t get exactly what do you need.","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"9c5c642edf40bf409e2cbbed93e7d0911b9b8975","unresolved":false,"context_lines":[{"line_number":90,"context_line":"        swift_connection.put_object(project_id, project_id, data)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"        for instance_id in instance_ids:"},{"line_number":93,"context_line":"            container_id \u003d \"{0}_{1}\".format(project_id, instance_id)"},{"line_number":94,"context_line":"            # Create new storage per instance"},{"line_number":95,"context_line":"            self.storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":96,"context_line":"                                              container_id,"}],"source_content_type":"text/x-python","patch_set":28,"id":"da4df55a_76b4a681","line":93,"updated":"2016-12-26 14:51:18.000000000","message":"ditto","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"e2754677b96aea2286b3141db7fff734ee066b0c","unresolved":false,"context_lines":[{"line_number":88,"context_line":"        swift_connection \u003d self.storage.client_manager.create_swift()"},{"line_number":89,"context_line":"        data \u003d json.dumps(instance_ids)"},{"line_number":90,"context_line":"        LOG.info(\"Saving information about instances {0}\".format(data))"},{"line_number":91,"context_line":"        swift_connection.put_object(project_id, \"instance_\" + project_id, data)"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"        for instance_id in instance_ids:"},{"line_number":94,"context_line":"            container_id \u003d \"{0}_instance_{1}\".format(project_id, instance_id)"}],"source_content_type":"text/x-python","patch_set":31,"id":"ba5201f7_0c90b642","line":91,"range":{"start_line":91,"start_character":25,"end_line":91,"end_character":35},"updated":"2017-01-04 17:04:17.000000000","message":"Hmm, I just noticed that add_stream() (https://github.com/openstack/freezer/blob/01b8f8922083835c2c09054c627f17f66cbea9a3/freezer/storage/swift.py#L161-L181) tries to hide some details about how exactly an object is uploaded, e.g. it uses a specific container name, that can be specified as a command line option and also handles the segmentation (which is apparently important for files larger than 5 GBs, according  to http://docs.openstack.org/developer/swift/overview_large_objects.html )\n\nI suggest you try backup/restore procedure on large VMs, but overall add_stream() seems a preferable API to use .","commit_id":"d0ecb86c31d967f6ca361e5ad787e80582eb6d7d"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"6448501ce2314c9d9b88f88e1140b7b04aa45426","unresolved":false,"context_lines":[{"line_number":88,"context_line":"        swift_connection \u003d self.storage.client_manager.create_swift()"},{"line_number":89,"context_line":"        data \u003d json.dumps(instance_ids)"},{"line_number":90,"context_line":"        LOG.info(\"Saving information about instances {0}\".format(data))"},{"line_number":91,"context_line":"        swift_connection.put_object(project_id, \"instance_\" + project_id, data)"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"        for instance_id in instance_ids:"},{"line_number":94,"context_line":"            container_id \u003d \"{0}_instance_{1}\".format(project_id, instance_id)"}],"source_content_type":"text/x-python","patch_set":31,"id":"ba5201f7_acd7aabd","line":91,"range":{"start_line":91,"start_character":25,"end_line":91,"end_character":35},"in_reply_to":"ba5201f7_0c90b642","updated":"2017-01-04 17:07:03.000000000","message":"ah, sorry, you still use backup_nova() for each VM, so it must be fine","commit_id":"d0ecb86c31d967f6ca361e5ad787e80582eb6d7d"}],"freezer/openstack/restore.py":[{"author":{"_account_id":6508,"name":"Dmitry Stepanenko","email":"dstepanenko@mirantis.com","username":"dstepanenko"},"change_message_id":"84540805af0953903e99117da79f28ec8774a166","unresolved":false,"context_lines":[{"line_number":234,"context_line":"                            max_chunk_size):"},{"line_number":235,"context_line":"        client_manager \u003d self.client_manager"},{"line_number":236,"context_line":"        # Load info about tenant instances in swift"},{"line_number":237,"context_line":"        storage \u003d swift.SwiftStorage(client_manager,"},{"line_number":238,"context_line":"                                     project_id,"},{"line_number":239,"context_line":"                                     max_chunk_size)"},{"line_number":240,"context_line":"        swift_connection \u003d storage.client_manager.create_swift()"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a6eadb0_55905a43","line":237,"updated":"2016-12-21 11:10:48.000000000","message":"same here. After merge of \"backup to local\" patch, self.storage contains instance of appropriate storage, so use it instead os instantiating SwiftStorage","commit_id":"7483241f03a5a4a6384b46c1b044d0aa2c7724f3"}],"freezer/tests/unit/openstack/test_backup.py":[{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"9c5c642edf40bf409e2cbbed93e7d0911b9b8975","unresolved":false,"context_lines":[{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"class TestBackup(commons.FreezerBaseTestCase):"},{"line_number":27,"context_line":"    def setUp(self):"},{"line_number":28,"context_line":"        super(TestBackup, self).setUp()"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    @mock.patch(\"freezer.openstack.backup.BackupOs.backup_nova\")"}],"source_content_type":"text/x-python","patch_set":28,"id":"da4df55a_ca3cc2ca","line":27,"updated":"2016-12-26 14:51:18.000000000","message":"nit: this does nothing and can be safely removed","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"6a1e7d44eefc2e592a86ac5bf74b8fc4cb7829e7","unresolved":false,"context_lines":[{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"class TestBackup(commons.FreezerBaseTestCase):"},{"line_number":27,"context_line":"    def setUp(self):"},{"line_number":28,"context_line":"        super(TestBackup, self).setUp()"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    @mock.patch(\"freezer.openstack.backup.BackupOs.backup_nova\")"}],"source_content_type":"text/x-python","patch_set":28,"id":"ba5201f7_62036d74","line":27,"in_reply_to":"da4df55a_ca3cc2ca","updated":"2016-12-30 11:11:13.000000000","message":"Yeah, I\u0027ve copied this test and I\u0027ve decided to leave this thing.","commit_id":"75e947cc91c8c5d924eac77881fa55d2fa5c0e2c"}],"freezer/tests/unit/openstack/test_restore.py":[{"author":{"_account_id":6508,"name":"Dmitry Stepanenko","email":"dstepanenko@mirantis.com","username":"dstepanenko"},"change_message_id":"84540805af0953903e99117da79f28ec8774a166","unresolved":false,"context_lines":[{"line_number":77,"context_line":"            mock_swift_connection"},{"line_number":78,"context_line":"        mock_body \u003d mock.MagicMock()"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"        def read():"},{"line_number":81,"context_line":"            return mock_str"},{"line_number":82,"context_line":"        mock_body.read \u003d read"},{"line_number":83,"context_line":"        mock_swift_connection.get_object.return_value \u003d (None, mock_body)"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a6eadb0_b55c4e7e","line":80,"updated":"2016-12-21 11:10:48.000000000","message":"what do you think about renaming read into mock_read here?","commit_id":"7483241f03a5a4a6384b46c1b044d0aa2c7724f3"},{"author":{"_account_id":12712,"name":"Gleb Stepanov","email":"gstepanov@mirantis.com","username":"stgleb"},"change_message_id":"fc28b5fc7a91e42ba080fdc291bcdb1bc0ffbe78","unresolved":false,"context_lines":[{"line_number":77,"context_line":"            mock_swift_connection"},{"line_number":78,"context_line":"        mock_body \u003d mock.MagicMock()"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"        def read():"},{"line_number":81,"context_line":"            return mock_str"},{"line_number":82,"context_line":"        mock_body.read \u003d read"},{"line_number":83,"context_line":"        mock_swift_connection.get_object.return_value \u003d (None, mock_body)"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a6eadb0_744e2f70","line":80,"in_reply_to":"1a6eadb0_b55c4e7e","updated":"2016-12-21 13:51:59.000000000","message":"Good point","commit_id":"7483241f03a5a4a6384b46c1b044d0aa2c7724f3"}]}
