)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":11903,"name":"Anthony Lee","email":"anthony.mic.lee@hpe.com","username":"leeantho"},"change_message_id":"b941665130342ad80b1a3bca95aa7e62dc6382aa","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Yusuke Hayashi \u003chayashi-yusuke@jp.fujitsu.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-11-16 22:54:16 +0900"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add argment for efficient sparse image transfer"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"fetch_to_raw writes qcow2 image to volume by \u0027qemu-img convert\u0027."},{"line_number":10,"context_line":"When the large part of the image is sparse data, this is unefficient"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba8a016a_d896f693","line":7,"updated":"2015-11-17 01:16:53.000000000","message":"argment -\u003e argument","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"4244fa01ecc34a9a052d8c9bcbe63cc0ed96f8a4","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add argment for efficient sparse image transfer"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"fetch_to_raw writes qcow2 image to volume by \u0027qemu-img convert\u0027."},{"line_number":10,"context_line":"When the large part of the image is sparse data, this is unefficient"},{"line_number":11,"context_line":"because this command writes sparse data to volume without skipping it."},{"line_number":12,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba8a016a_a5b0ca8c","line":9,"updated":"2015-11-16 14:52:41.000000000","message":"convert -\u003e conversion ?","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":10674,"name":"Yusuke Hayashi","email":"yusuke.hayashi.710@gmail.com","username":"YusukeHayashi"},"change_message_id":"6e766a8041d2d1b8e773c1bdcfdff967117a9c2a","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add argment for efficient sparse image transfer"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"fetch_to_raw writes qcow2 image to volume by \u0027qemu-img convert\u0027."},{"line_number":10,"context_line":"When the large part of the image is sparse data, this is unefficient"},{"line_number":11,"context_line":"because this command writes sparse data to volume without skipping it."},{"line_number":12,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba8a016a_02872fb6","line":9,"in_reply_to":"ba8a016a_a5b0ca8c","updated":"2015-11-17 00:35:31.000000000","message":"This is command name. I\u0027m sorry to use confusing expression.","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"4244fa01ecc34a9a052d8c9bcbe63cc0ed96f8a4","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Add argment for efficient sparse image transfer"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"fetch_to_raw writes qcow2 image to volume by \u0027qemu-img convert\u0027."},{"line_number":10,"context_line":"When the large part of the image is sparse data, this is unefficient"},{"line_number":11,"context_line":"because this command writes sparse data to volume without skipping it."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"As 1st step, this patch adds the argment for skipping sparce data as below:"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba8a016a_e2fd686f","line":10,"updated":"2015-11-16 14:52:41.000000000","message":"unefficient -\u003e inefficient","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":17405,"name":"Jacob Gregor","email":"jgregor@us.ibm.com","username":"jgregor"},"change_message_id":"13422c7f6fc2ac716ff7b9719aa7b0773105de3a","unresolved":false,"context_lines":[{"line_number":10,"context_line":"When the large part of the image is sparse data, this is unefficient"},{"line_number":11,"context_line":"because this command writes sparse data to volume without skipping it."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"As 1st step, this patch adds the argment for skipping sparce data as below:"},{"line_number":14,"context_line":"1. download qcow2 image from Glance (same as before)"},{"line_number":15,"context_line":"2. extract it into raw format in local system by \u0027qemu-img convert\u0027"},{"line_number":16,"context_line":"3. write it to volume by \u0027dd xxx conv\u003dsparse\u0027"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba8a016a_5c81b38e","line":13,"updated":"2015-11-16 16:06:36.000000000","message":"sparce -\u003e sparse","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"4244fa01ecc34a9a052d8c9bcbe63cc0ed96f8a4","unresolved":false,"context_lines":[{"line_number":16,"context_line":"3. write it to volume by \u0027dd xxx conv\u003dsparse\u0027"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"This does not use the argment as regular action, because this improvement"},{"line_number":19,"context_line":"requires many free area in local system."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"As for client UI, other patch will solve it."},{"line_number":22,"context_line":"This patch focuses on preparing interface in image_util.py"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba8a016a_05175652","line":19,"updated":"2015-11-16 14:52:41.000000000","message":"Suggest: \"...this improvement require a lot of free space in the local system.\" ?","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"4244fa01ecc34a9a052d8c9bcbe63cc0ed96f8a4","unresolved":false,"context_lines":[{"line_number":18,"context_line":"This does not use the argment as regular action, because this improvement"},{"line_number":19,"context_line":"requires many free area in local system."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"As for client UI, other patch will solve it."},{"line_number":22,"context_line":"This patch focuses on preparing interface in image_util.py"},{"line_number":23,"context_line":"for cinder, cinder client, and volume drivers."},{"line_number":24,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba8a016a_a83ae1cb","line":21,"updated":"2015-11-16 14:52:41.000000000","message":"Do you have the other patch in the community already? Might be helpful to link it here if it is.","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":10674,"name":"Yusuke Hayashi","email":"yusuke.hayashi.710@gmail.com","username":"YusukeHayashi"},"change_message_id":"6e766a8041d2d1b8e773c1bdcfdff967117a9c2a","unresolved":false,"context_lines":[{"line_number":18,"context_line":"This does not use the argment as regular action, because this improvement"},{"line_number":19,"context_line":"requires many free area in local system."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"As for client UI, other patch will solve it."},{"line_number":22,"context_line":"This patch focuses on preparing interface in image_util.py"},{"line_number":23,"context_line":"for cinder, cinder client, and volume drivers."},{"line_number":24,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ba8a016a_bdbbe40d","line":21,"in_reply_to":"ba8a016a_a83ae1cb","updated":"2015-11-17 00:35:31.000000000","message":"I have no implemention now, sorry..\nI think there are 3 way to implement it.\n\n\n1) use the option of cinder.conf such as below:\n\n----------------\n\n[backend_name]\n\n...\n\nuse_dd_sparse_for_image_xfer \u003d True\n\n----------------\n\n(pros) it\u0027s easy to configure \n\n(cons) when the backend is used, all image will be conveted in local\n\n\n\n2) use extra specs with volume type such as \u0027dd_sparse \u003cis\u003e True\u0027\n\n(pros) user can select the way for each the image\n\n(cons) \nwhen I use the way, I need to implement it in driver.py.\nBut I cannot see the processing of checking extra_specs from volume_type in driver.py. So, I\u0027m not sure there is no problem with implementing it in driver.py or not.. If possible, it may be better to leave it to each vendor driver.\n\n\n\n3) implement as external api such as below command:\n\n$ cinder create --image-id \u003cid\u003e --dd_sparse True \u003cvolume_size\u003e\n\n(pros) very intuitive for user\n\n(cons) user can use this option freely and cloud admin cannot controll it","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"}],"cinder/image/image_utils.py":[{"author":{"_account_id":10115,"name":"Mitsuhiro Tanino","email":"mitsuhiro.tanino@lycorp.co.jp","username":"mtanino"},"change_message_id":"9229baa267bd51896a119452a130194bb8c74e2e","unresolved":false,"context_lines":[{"line_number":148,"context_line":"                       out_format, run_as_root\u003drun_as_root)"},{"line_number":149,"context_line":""},{"line_number":150,"context_line":""},{"line_number":151,"context_line":"def convert_image_with_dd_sparse(source, dest, out_format, blocksize,"},{"line_number":152,"context_line":"                                 run_as_root\u003dTrue, throttle\u003dNone):"},{"line_number":153,"context_line":""},{"line_number":154,"context_line":"    \"\"\"Convert image to other format and write using dd with sparse option.\"\"\""}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_c1bcc26e","line":151,"updated":"2015-11-17 02:21:50.000000000","message":"We should add log output to this method as same level as _convert_image at least.","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":10439,"name":"Xi Yang","email":"yang.xi@99cloud.net","username":"phenom"},"change_message_id":"d5787beb0788022d4d019c1cea0b95922db458ec","unresolved":false,"context_lines":[{"line_number":340,"context_line":"        # check via \u0027qemu-img info\u0027 that what we copied was in fact a raw"},{"line_number":341,"context_line":"        # image and not a different format with a backing file, which may be"},{"line_number":342,"context_line":"        # malicious."},{"line_number":343,"context_line":"        LOG.debug(\"%s was %s, converting to %s \", image_id, fmt, volume_format)"},{"line_number":344,"context_line":"        if not dd_sparse:"},{"line_number":345,"context_line":"            convert_image(tmp, dest, volume_format,"},{"line_number":346,"context_line":"                          run_as_root\u003drun_as_root)"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_4800ee34","line":343,"updated":"2015-11-17 07:05:14.000000000","message":"Better to log if we are using sparse here.","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":10115,"name":"Mitsuhiro Tanino","email":"mitsuhiro.tanino@lycorp.co.jp","username":"mtanino"},"change_message_id":"f1909a372ce36be8969fc346990d06047123907c","unresolved":false,"context_lines":[{"line_number":158,"context_line":"        cmd \u003d (\u0027qemu-img\u0027, \u0027convert\u0027,"},{"line_number":159,"context_line":"               \u0027-O\u0027, out_format, source, tmp_dest)"},{"line_number":160,"context_line":""},{"line_number":161,"context_line":"        fsz_mb \u003d os.stat(source).st_size / units.Mi"},{"line_number":162,"context_line":""},{"line_number":163,"context_line":"        start_time \u003d timeutils.utcnow()"},{"line_number":164,"context_line":"        utils.execute(*cmd, run_as_root\u003drun_as_root)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_24600e01","line":161,"updated":"2015-11-17 19:23:43.000000000","message":"Currently, bug fix is proposed for this line. IMO, we need to introduce same fix into this patch.\n\nhttps://review.openstack.org/#/c/243152/","commit_id":"e40e726cfe74144ea7821fde611fec1eecdc5da2"},{"author":{"_account_id":10115,"name":"Mitsuhiro Tanino","email":"mitsuhiro.tanino@lycorp.co.jp","username":"mtanino"},"change_message_id":"f1909a372ce36be8969fc346990d06047123907c","unresolved":false,"context_lines":[{"line_number":177,"context_line":"        msg \u003d (\"Image conversion details: src %(src)s, size %(sz).2f MB, \""},{"line_number":178,"context_line":"               \"temporary converted file %(tmp_dest)s, destination %(dest)s, \""},{"line_number":179,"context_line":"               \"convert-duration %(duration1).2f sec, \""},{"line_number":180,"context_line":"               \"dd-duration %(duration2).2f sec\")"},{"line_number":181,"context_line":"        LOG.debug(msg, {\"src\": source, \"sz\": fsz_mb,"},{"line_number":182,"context_line":"                        \"tmp_dest\": tmp_dest, \"dest\": dest,"},{"line_number":183,"context_line":"                        \"duration1\": conv_duration,"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_042ceaa9","line":180,"updated":"2015-11-17 19:23:43.000000000","message":"nit: please add \".\" end of the sentence.\n\nI know log in the _convert_image() does not have period at the end of log sentence.","commit_id":"e40e726cfe74144ea7821fde611fec1eecdc5da2"},{"author":{"_account_id":10115,"name":"Mitsuhiro Tanino","email":"mitsuhiro.tanino@lycorp.co.jp","username":"mtanino"},"change_message_id":"f1909a372ce36be8969fc346990d06047123907c","unresolved":false,"context_lines":[{"line_number":184,"context_line":"                        \"duration2\": dd_duration})"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"        mbps \u003d (fsz_mb / (conv_duration + dd_duration))"},{"line_number":187,"context_line":"        msg \u003d _LI(\"Converted %(sz).2f MB image at %(mbps).2f MB/s\")"},{"line_number":188,"context_line":"        LOG.info(msg, {\"sz\": fsz_mb, \"mbps\": mbps})"},{"line_number":189,"context_line":""},{"line_number":190,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_64fff667","line":187,"updated":"2015-11-17 19:23:43.000000000","message":"nit: please add \".\" end of the sentence.","commit_id":"e40e726cfe74144ea7821fde611fec1eecdc5da2"},{"author":{"_account_id":10115,"name":"Mitsuhiro Tanino","email":"mitsuhiro.tanino@lycorp.co.jp","username":"mtanino"},"change_message_id":"f1909a372ce36be8969fc346990d06047123907c","unresolved":false,"context_lines":[{"line_number":360,"context_line":"        # image and not a different format with a backing file, which may be"},{"line_number":361,"context_line":"        # malicious."},{"line_number":362,"context_line":"        if not dd_sparse:"},{"line_number":363,"context_line":"            LOG.debug(\"%s was %s, converting to %s\","},{"line_number":364,"context_line":"                      image_id, fmt, volume_format)"},{"line_number":365,"context_line":"            convert_image(tmp, dest, volume_format,"},{"line_number":366,"context_line":"                          run_as_root\u003drun_as_root)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_e407661a","line":363,"updated":"2015-11-17 19:23:43.000000000","message":"nit: please add \".\" end of the sentence.","commit_id":"e40e726cfe74144ea7821fde611fec1eecdc5da2"},{"author":{"_account_id":10115,"name":"Mitsuhiro Tanino","email":"mitsuhiro.tanino@lycorp.co.jp","username":"mtanino"},"change_message_id":"f1909a372ce36be8969fc346990d06047123907c","unresolved":false,"context_lines":[{"line_number":366,"context_line":"                          run_as_root\u003drun_as_root)"},{"line_number":367,"context_line":"        else:"},{"line_number":368,"context_line":"            LOG.debug(\"%s was %s, converting to %s in local and \""},{"line_number":369,"context_line":"                      \"writing with sparse skip option\","},{"line_number":370,"context_line":"                      image_id, fmt, volume_format)"},{"line_number":371,"context_line":"            convert_image_with_dd_sparse(tmp, dest, volume_format, blocksize,"},{"line_number":372,"context_line":"                                         run_as_root\u003drun_as_root)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_4479922e","line":369,"updated":"2015-11-17 19:23:43.000000000","message":"nit: please add \".\" end of the sentence.","commit_id":"e40e726cfe74144ea7821fde611fec1eecdc5da2"}],"cinder/tests/unit/test_image_utils.py":[{"author":{"_account_id":17405,"name":"Jacob Gregor","email":"jgregor@us.ibm.com","username":"jgregor"},"change_message_id":"13422c7f6fc2ac716ff7b9719aa7b0773105de3a","unresolved":false,"context_lines":[{"line_number":222,"context_line":"    @mock.patch(\u0027cinder.utils.execute\u0027)"},{"line_number":223,"context_line":"    @mock.patch(\u0027cinder.utils.is_blk_device\u0027, return_value\u003dFalse)"},{"line_number":224,"context_line":"    def test_defaults_not_block_dev(self, mock_isblk, mock_exec, mock_stat,"},{"line_number":225,"context_line":"                                    mock_temp, mock_copy, mock_odirect):"},{"line_number":226,"context_line":"        source \u003d mock.sentinel.source"},{"line_number":227,"context_line":"        tmp_dest \u003d mock_temp.return_value.__enter__.return_value"},{"line_number":228,"context_line":"        dest \u003d mock.sentinel.dest"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_31d5f842","line":225,"updated":"2015-11-16 16:06:36.000000000","message":"test_defaults_not_block_dev and the first test done in test_defaults_block_dev look identical to me. I think it would be a good idea to remove the first test being done in test_defaults_block_dev (lines 177 to 200) so that we avoid testing multiple situations in a single test.","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":10674,"name":"Yusuke Hayashi","email":"yusuke.hayashi.710@gmail.com","username":"YusukeHayashi"},"change_message_id":"6e766a8041d2d1b8e773c1bdcfdff967117a9c2a","unresolved":false,"context_lines":[{"line_number":222,"context_line":"    @mock.patch(\u0027cinder.utils.execute\u0027)"},{"line_number":223,"context_line":"    @mock.patch(\u0027cinder.utils.is_blk_device\u0027, return_value\u003dFalse)"},{"line_number":224,"context_line":"    def test_defaults_not_block_dev(self, mock_isblk, mock_exec, mock_stat,"},{"line_number":225,"context_line":"                                    mock_temp, mock_copy, mock_odirect):"},{"line_number":226,"context_line":"        source \u003d mock.sentinel.source"},{"line_number":227,"context_line":"        tmp_dest \u003d mock_temp.return_value.__enter__.return_value"},{"line_number":228,"context_line":"        dest \u003d mock.sentinel.dest"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_fda08c92","line":225,"in_reply_to":"ba8a016a_31d5f842","updated":"2015-11-17 00:35:31.000000000","message":"+1, I\u0027ll remove these lines in next update.","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":10674,"name":"Yusuke Hayashi","email":"yusuke.hayashi.710@gmail.com","username":"YusukeHayashi"},"change_message_id":"da607dae2b394916be4659176df084d10ed852fe","unresolved":false,"context_lines":[{"line_number":222,"context_line":"    @mock.patch(\u0027cinder.utils.execute\u0027)"},{"line_number":223,"context_line":"    @mock.patch(\u0027cinder.utils.is_blk_device\u0027, return_value\u003dFalse)"},{"line_number":224,"context_line":"    def test_defaults_not_block_dev(self, mock_isblk, mock_exec, mock_stat,"},{"line_number":225,"context_line":"                                    mock_temp, mock_copy, mock_odirect):"},{"line_number":226,"context_line":"        source \u003d mock.sentinel.source"},{"line_number":227,"context_line":"        tmp_dest \u003d mock_temp.return_value.__enter__.return_value"},{"line_number":228,"context_line":"        dest \u003d mock.sentinel.dest"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_c2cd8e5e","line":225,"in_reply_to":"ba8a016a_fda08c92","updated":"2015-11-17 11:49:45.000000000","message":"Oh, sorry. I misunderstand it. Expected result of line 177-200 are different from l.200-. That\u0027s why I split l.177-215 into two tests.","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"},{"author":{"_account_id":17405,"name":"Jacob Gregor","email":"jgregor@us.ibm.com","username":"jgregor"},"change_message_id":"13422c7f6fc2ac716ff7b9719aa7b0773105de3a","unresolved":false,"context_lines":[{"line_number":698,"context_line":"    @mock.patch(\u0027cinder.image.image_utils.qemu_img_info\u0027)"},{"line_number":699,"context_line":"    @mock.patch(\u0027cinder.image.image_utils.temporary_file\u0027)"},{"line_number":700,"context_line":"    @mock.patch(\u0027cinder.image.image_utils.CONF\u0027)"},{"line_number":701,"context_line":"    def test_dd_spase(self, mock_conf, mock_temp, mock_info, mock_fetch,"},{"line_number":702,"context_line":"                      mock_is_xen, mock_repl_xen, mock_copy, mock_convert):"},{"line_number":703,"context_line":"        ctxt \u003d mock.sentinel.context"},{"line_number":704,"context_line":"        ctxt.user_id \u003d mock.sentinel.user_id"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_2837d1b1","line":701,"updated":"2015-11-16 16:06:36.000000000","message":"test_dd_spase -\u003e test_dd_sparse","commit_id":"96ebf204e7afeab50fda1a1a677bdce6ef2ac468"}]}
