)]}'
{"ironic/common/images.py":[{"author":{"_account_id":7711,"name":"Yuriy Zveryanskyy","email":"yzveryanskyy@mirantis.com","username":"yuriyz"},"change_message_id":"5d3b8dc68b8122bda6f43a0e992b03bae5233ba8","unresolved":false,"context_lines":[{"line_number":41,"context_line":"image_opts \u003d ["},{"line_number":42,"context_line":"    cfg.BoolOpt(\u0027force_raw_images\u0027,"},{"line_number":43,"context_line":"                default\u003dTrue,"},{"line_number":44,"context_line":"                help\u003d\u0027Force backing images to raw format.\u0027),"},{"line_number":45,"context_line":"    cfg.StrOpt(\u0027isolinux_bin\u0027,"},{"line_number":46,"context_line":"                default\u003d\u0027/usr/lib/syslinux/isolinux.bin\u0027,"},{"line_number":47,"context_line":"                help\u003d\u0027Path to isolinux binary file.\u0027),"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_bc0b6c22","line":44,"updated":"2014-10-28 09:49:00.000000000","message":"You should change help string if usage was changed.","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"},{"author":{"_account_id":4573,"name":"yunhong-jiang","email":"yunhong.jiang@intel.com","username":"yunhong-jiang"},"change_message_id":"51871b67f68c0a45679dd2491245260309efd7fc","unresolved":false,"context_lines":[{"line_number":41,"context_line":"image_opts \u003d ["},{"line_number":42,"context_line":"    cfg.BoolOpt(\u0027force_raw_images\u0027,"},{"line_number":43,"context_line":"                default\u003dTrue,"},{"line_number":44,"context_line":"                help\u003d\u0027Force backing images to raw format.\u0027),"},{"line_number":45,"context_line":"    cfg.StrOpt(\u0027isolinux_bin\u0027,"},{"line_number":46,"context_line":"                default\u003d\u0027/usr/lib/syslinux/isolinux.bin\u0027,"},{"line_number":47,"context_line":"                help\u003d\u0027Path to isolinux binary file.\u0027),"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_94b2f4e2","line":44,"in_reply_to":"9aa7fdbe_bc0b6c22","updated":"2014-10-28 17:05:25.000000000","message":"Hi, the subject of \"usage\" is not about changing the meaning of this config, instead, it\u0027s more about how this config used. Previously, it\u0027s used in the image level, and this patch changes it to the deploy level.","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"}],"ironic/drivers/modules/deploy_utils.py":[{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"561612c209beb4ada2120c97be5e6624b19f30ba","unresolved":false,"context_lines":[{"line_number":207,"context_line":"    if not virtual_size:"},{"line_number":208,"context_line":"        image_byte \u003d os.path.getsize(image_path)"},{"line_number":209,"context_line":"    else:"},{"line_number":210,"context_line":"        image_byte \u003d images.converted_size(image_path)"},{"line_number":211,"context_line":"    # round up size to MB"},{"line_number":212,"context_line":"    image_mb \u003d int((image_byte + mb - 1) / mb)"},{"line_number":213,"context_line":"    return image_mb"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_b25ab5ef","line":210,"updated":"2014-10-28 11:09:44.000000000","message":"Maybe it\u0027s better to make it dynamic?\n\ne.g: \n\n data \u003d qemu_img_info(path)\n if data.file_format \u003d\u003d \"raw\":\n     image_byte \u003d os.path.getsize(image_path)\n else:\n     image_byte \u003d images.converted_size(image_path)","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"},{"author":{"_account_id":4573,"name":"yunhong-jiang","email":"yunhong.jiang@intel.com","username":"yunhong-jiang"},"change_message_id":"51871b67f68c0a45679dd2491245260309efd7fc","unresolved":false,"context_lines":[{"line_number":207,"context_line":"    if not virtual_size:"},{"line_number":208,"context_line":"        image_byte \u003d os.path.getsize(image_path)"},{"line_number":209,"context_line":"    else:"},{"line_number":210,"context_line":"        image_byte \u003d images.converted_size(image_path)"},{"line_number":211,"context_line":"    # round up size to MB"},{"line_number":212,"context_line":"    image_mb \u003d int((image_byte + mb - 1) / mb)"},{"line_number":213,"context_line":"    return image_mb"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_34ca281b","line":210,"in_reply_to":"9aa7fdbe_b25ab5ef","updated":"2014-10-28 17:05:25.000000000","message":"Hi, Lucas, in my mind, a image size has two meaning, at least for compressed image. It can be the size of the image file itself, or it can be the size of the raw file. Thus we passing a parameter to determine if the caller want the virtual size or the image size. For qcow2, these values will be different, while for raw image file, these values are same. \n\nIn your code, we in fact always return the virtual size.\n\nYour opinion?","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"}],"ironic/drivers/modules/image_cache.py":[{"author":{"_account_id":7711,"name":"Yuriy Zveryanskyy","email":"yzveryanskyy@mirantis.com","username":"yuriyz"},"change_message_id":"5d3b8dc68b8122bda6f43a0e992b03bae5233ba8","unresolved":false,"context_lines":[{"line_number":72,"context_line":"        if master_dir is not None:"},{"line_number":73,"context_line":"            fileutils.ensure_tree(master_dir)"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"    def fetch_image(self, uuid, dest_path, ctx\u003dNone, force_raw\u003dTrue):"},{"line_number":76,"context_line":"        \"\"\"Fetch image with given uuid to the destination path."},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"        Does nothing if destination path exists."}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_881bc77f","line":75,"updated":"2014-10-28 09:49:00.000000000","message":"I prefer to use config option directly instead of parameter.","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"},{"author":{"_account_id":4573,"name":"yunhong-jiang","email":"yunhong.jiang@intel.com","username":"yunhong-jiang"},"change_message_id":"51871b67f68c0a45679dd2491245260309efd7fc","unresolved":false,"context_lines":[{"line_number":72,"context_line":"        if master_dir is not None:"},{"line_number":73,"context_line":"            fileutils.ensure_tree(master_dir)"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"    def fetch_image(self, uuid, dest_path, ctx\u003dNone, force_raw\u003dTrue):"},{"line_number":76,"context_line":"        \"\"\"Fetch image with given uuid to the destination path."},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"        Does nothing if destination path exists."}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_b479b8c9","line":75,"in_reply_to":"9aa7fdbe_881bc77f","updated":"2014-10-28 17:05:25.000000000","message":"I think one purpose of the patch is, the low level code should not care for the deploy option like force_raw_image or not. Such deploy policy should only be cared by the upper deploy level. After all, these low level image code will be used by different deploy codes, and in future, maybe different deploy mechanism want different config.","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"561612c209beb4ada2120c97be5e6624b19f30ba","unresolved":false,"context_lines":[{"line_number":81,"context_line":""},{"line_number":82,"context_line":"        :param uuid: image UUID or href to fetch"},{"line_number":83,"context_line":"        :param dest_path: destination file path"},{"line_number":84,"context_line":"        :param ctx: context"},{"line_number":85,"context_line":"        \"\"\""},{"line_number":86,"context_line":"        img_download_lock_name \u003d \u0027download-image\u0027"},{"line_number":87,"context_line":"        if self.master_dir is None:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_928131fd","line":84,"updated":"2014-10-28 11:09:44.000000000","message":":param force_raw: Boolean value, whether to convert image to raw format prior to deploying it or not.\n\nOr something like that","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"},{"author":{"_account_id":4573,"name":"yunhong-jiang","email":"yunhong.jiang@intel.com","username":"yunhong-jiang"},"change_message_id":"51871b67f68c0a45679dd2491245260309efd7fc","unresolved":false,"context_lines":[{"line_number":81,"context_line":""},{"line_number":82,"context_line":"        :param uuid: image UUID or href to fetch"},{"line_number":83,"context_line":"        :param dest_path: destination file path"},{"line_number":84,"context_line":"        :param ctx: context"},{"line_number":85,"context_line":"        \"\"\""},{"line_number":86,"context_line":"        img_download_lock_name \u003d \u0027download-image\u0027"},{"line_number":87,"context_line":"        if self.master_dir is None:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_3498681b","line":84,"in_reply_to":"9aa7fdbe_928131fd","updated":"2014-10-28 17:05:25.000000000","message":"Aha, good point. Forgot adding the parameters.","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"561612c209beb4ada2120c97be5e6624b19f30ba","unresolved":false,"context_lines":[{"line_number":139,"context_line":"        :param uuid: image UUID or href to fetch"},{"line_number":140,"context_line":"        :param master_path: destination master path"},{"line_number":141,"context_line":"        :param dest_path: destination file path"},{"line_number":142,"context_line":"        :param ctx: context"},{"line_number":143,"context_line":"        \"\"\""},{"line_number":144,"context_line":"        #TODO(ghe): timeout and retry for downloads"},{"line_number":145,"context_line":"        #TODO(ghe): logging when image cannot be created"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_f2c7dd42","line":142,"updated":"2014-10-28 11:09:44.000000000","message":":param force_raw: Boolean value, whether to convert image to raw format prior to deploying it or not.\n\nOr something like that","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"},{"author":{"_account_id":4573,"name":"yunhong-jiang","email":"yunhong.jiang@intel.com","username":"yunhong-jiang"},"change_message_id":"51871b67f68c0a45679dd2491245260309efd7fc","unresolved":false,"context_lines":[{"line_number":139,"context_line":"        :param uuid: image UUID or href to fetch"},{"line_number":140,"context_line":"        :param master_path: destination master path"},{"line_number":141,"context_line":"        :param dest_path: destination file path"},{"line_number":142,"context_line":"        :param ctx: context"},{"line_number":143,"context_line":"        \"\"\""},{"line_number":144,"context_line":"        #TODO(ghe): timeout and retry for downloads"},{"line_number":145,"context_line":"        #TODO(ghe): logging when image cannot be created"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_9414b44d","line":142,"in_reply_to":"9aa7fdbe_f2c7dd42","updated":"2014-10-28 17:05:25.000000000","message":"Thanks. Will do that. I will also check other code to see if missed also.","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"},{"author":{"_account_id":7711,"name":"Yuriy Zveryanskyy","email":"yzveryanskyy@mirantis.com","username":"yuriyz"},"change_message_id":"5d3b8dc68b8122bda6f43a0e992b03bae5233ba8","unresolved":false,"context_lines":[{"line_number":291,"context_line":"    path_tmp \u003d \"%s.part\" % path"},{"line_number":292,"context_line":"    images.fetch(context, image_href, path_tmp, image_service,"},{"line_number":293,"context_line":"                 force_raw\u003dFalse)"},{"line_number":294,"context_line":"    # Notes(yjiang5): If glance can provide the virtual size information,"},{"line_number":295,"context_line":"    # then we can firstly clean cach and then invoke images.fetch()."},{"line_number":296,"context_line":"    if force_raw:"},{"line_number":297,"context_line":"        required_space \u003d images.converted_size(path_tmp)"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_688dc3d2","line":294,"updated":"2014-10-28 09:49:00.000000000","message":"qemu-img used for virtual size information, AFAIK this info in Glance is optional. And we should modify converted_size() for trying to get virtual size from Glance.","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"},{"author":{"_account_id":4573,"name":"yunhong-jiang","email":"yunhong.jiang@intel.com","username":"yunhong-jiang"},"change_message_id":"51871b67f68c0a45679dd2491245260309efd7fc","unresolved":false,"context_lines":[{"line_number":291,"context_line":"    path_tmp \u003d \"%s.part\" % path"},{"line_number":292,"context_line":"    images.fetch(context, image_href, path_tmp, image_service,"},{"line_number":293,"context_line":"                 force_raw\u003dFalse)"},{"line_number":294,"context_line":"    # Notes(yjiang5): If glance can provide the virtual size information,"},{"line_number":295,"context_line":"    # then we can firstly clean cach and then invoke images.fetch()."},{"line_number":296,"context_line":"    if force_raw:"},{"line_number":297,"context_line":"        required_space \u003d images.converted_size(path_tmp)"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_946f54fb","line":294,"in_reply_to":"9aa7fdbe_688dc3d2","updated":"2014-10-28 17:05:25.000000000","message":"I asked glance person, and they said the virtual size support is not added yet although it has been proposed long before. I also talked with NobodyCam, and we agree that we don\u0027t want to depends on glance\u0027s virtual size support, so we add ironic change firstly. Later, if glance has such support, we can then add corresponding ironic changes.\n\nI will work on the glance side after the ironic changes merged.","commit_id":"bdbed8cd368ee85e73b88d8ff127286bb9f49a2f"}]}
