)]}'
{"nova/virt/libvirt/driver.py":[{"author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"tag":"autogenerated:zuul:check","change_message_id":"a85ba946704fc442f86d55d7d85482d918d2ad8b","unresolved":false,"context_lines":[{"line_number":3168,"context_line":"                    volume_path \u003d os.path.dirname("},{"line_number":3169,"context_line":"                        active_disk_object.source_path)"},{"line_number":3170,"context_line":"                    base_file \u003d os.path.join(volume_path, base_file_name)"},{"line_number":3171,"context_line":""},{"line_number":3172,"context_line":"                if os.path.isabs(commit_top):"},{"line_number":3173,"context_line":"                    commit_top_file \u003d commit_top"},{"line_number":3174,"context_line":"                else:"}],"source_content_type":"text/x-python","patch_set":1,"id":"9f560f44_eacbfca0","line":3171,"updated":"2020-10-06 20:37:17.000000000","message":"pep8: E303 too many blank lines (3)","commit_id":"1801dfbb5438529e616e28e9379b357651ecaa8a"},{"author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"tag":"autogenerated:zuul:check","change_message_id":"a85ba946704fc442f86d55d7d85482d918d2ad8b","unresolved":false,"context_lines":[{"line_number":3180,"context_line":""},{"line_number":3181,"context_line":"            qemu_img_extra_arg \u003d [commit_top_file]"},{"line_number":3182,"context_line":"            # execute operation with disk concurrency semaphore"},{"line_number":3183,"context_line":"            LOG.info(\u0027+++++COMPLETING WITH base_file : %s and\u0027"},{"line_number":3184,"context_line":"                     \u0027source file : %s\u0027 % (base_file, qemu_img_extra_arg))"},{"line_number":3185,"context_line":"            with compute_utils.disk_ops_semaphore:"},{"line_number":3186,"context_line":"                processutils.execute(\"qemu-img\", \"commit\", \"-b\", base_file,"}],"source_content_type":"text/x-python","patch_set":1,"id":"9f560f44_0ac910ab","line":3183,"updated":"2020-10-06 20:37:17.000000000","message":"pep8: H904: String interpolation should be delayed to be handled by the logging code, rather than being done at the point of the logging call. Use \u0027,\u0027 instead of \u0027%\u0027.","commit_id":"1801dfbb5438529e616e28e9379b357651ecaa8a"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"1c388b1f2be26f75e252e5272ffa3ebc3bf22b90","unresolved":false,"context_lines":[{"line_number":3183,"context_line":"            LOG.info(\u0027+++++COMPLETING WITH base_file : %s and\u0027"},{"line_number":3184,"context_line":"                     \u0027source file : %s\u0027 % (base_file, qemu_img_extra_arg))"},{"line_number":3185,"context_line":"            with compute_utils.disk_ops_semaphore:"},{"line_number":3186,"context_line":"                processutils.execute(\"qemu-img\", \"commit\", \"-b\", base_file,"},{"line_number":3187,"context_line":"                                     *qemu_img_extra_arg)"},{"line_number":3188,"context_line":""},{"line_number":3189,"context_line":""},{"line_number":3190,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"9f560f44_d0623415","line":3187,"range":{"start_line":3186,"start_character":1,"end_line":3187,"end_character":57},"updated":"2020-10-06 11:25:47.000000000","message":"[While knowing that this is a WIP ... you need to provide more explanation in terms of use case, etc for doing \"offline block commit\".\n\nThe original use case for introducing run-time blockCommit() in Nova was to be able to delete volume snapshots (particularly network-attached disks).\n\n(Aside: don\u0027t want to directly use \u0027qemu-img\u0027 in driver.py; ideally, a wrapper method in nova/virt/libvirt/utils.py)","commit_id":"1801dfbb5438529e616e28e9379b357651ecaa8a"},{"author":{"_account_id":27615,"name":"Rajat Dhasmana","email":"rajatdhasmana@gmail.com","username":"whoami-rajat"},"change_message_id":"be89013be3fe1a6acad0ca455156d162226bd5dc","unresolved":false,"context_lines":[{"line_number":3183,"context_line":"            LOG.info(\u0027+++++COMPLETING WITH base_file : %s and\u0027"},{"line_number":3184,"context_line":"                     \u0027source file : %s\u0027 % (base_file, qemu_img_extra_arg))"},{"line_number":3185,"context_line":"            with compute_utils.disk_ops_semaphore:"},{"line_number":3186,"context_line":"                processutils.execute(\"qemu-img\", \"commit\", \"-b\", base_file,"},{"line_number":3187,"context_line":"                                     *qemu_img_extra_arg)"},{"line_number":3188,"context_line":""},{"line_number":3189,"context_line":""},{"line_number":3190,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"9f560f44_fce6134a","line":3187,"range":{"start_line":3186,"start_character":1,"end_line":3187,"end_character":57},"in_reply_to":"9f560f44_d0623415","updated":"2020-10-08 01:58:29.000000000","message":"The same case applies to offline block commit as well.\nSuppose we use nova image-create to create a disk snapshot chain like: vol1 -\u003e snap1 -\u003e snap2\nand we want to delete snap1 (from cinder side) when the VM is stopped/shutdown, this code will be called (which is a valid usecase and not supported yet)\n\nRegarding the qemu-img called directly, I\u0027ve used the same approach as done on L#2969 for qemu-img rebase command","commit_id":"1801dfbb5438529e616e28e9379b357651ecaa8a"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"29cfcd10e352123d5df4856dd5767367fce7fe81","unresolved":false,"context_lines":[{"line_number":3183,"context_line":"            LOG.info(\u0027+++++COMPLETING WITH base_file : %s and\u0027"},{"line_number":3184,"context_line":"                     \u0027source file : %s\u0027 % (base_file, qemu_img_extra_arg))"},{"line_number":3185,"context_line":"            with compute_utils.disk_ops_semaphore:"},{"line_number":3186,"context_line":"                processutils.execute(\"qemu-img\", \"commit\", \"-b\", base_file,"},{"line_number":3187,"context_line":"                                     *qemu_img_extra_arg)"},{"line_number":3188,"context_line":""},{"line_number":3189,"context_line":""},{"line_number":3190,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"9f560f44_b3284698","line":3187,"range":{"start_line":3186,"start_character":1,"end_line":3187,"end_character":57},"in_reply_to":"9f560f44_fce6134a","updated":"2020-10-08 09:57:49.000000000","message":"(Ah, ignore the point about \u0027qemu-img\u0027 usage directly; that\u0027s fine.)\n\nAnd based on IRC chat, you\u0027d want the arrows to backing files to point the other way:\n\n    vol1 \u003c- snap1 \u003c- snap2\n\nIIUC, you want to support deleting snap1.  Here once you commit \u0027snap1\u0027 into \u0027vol1\u0027, then you can update the backing file of \u0027snap2\u0027 to \u0027vol1\u0027 using `qemu-img rebase`[1]\n\nThat said, yeah, how Nova and Cinder are sharing info is something I need to look deeper...\n\n[1] Here\u0027s a little doc on offline usage of rebase/commit:\nhttps://kashyapc.fedorapeople.org/Offline-rebase-commit-and-convert.txt","commit_id":"1801dfbb5438529e616e28e9379b357651ecaa8a"},{"author":{"_account_id":10135,"name":"Lee Yarwood","display_name":"Lee Yarwood","email":"lyarwood@redhat.com","username":"lyarwood"},"change_message_id":"858178cbba09fdfe7251e3ad19846026eb4af00b","unresolved":true,"context_lines":[{"line_number":3180,"context_line":""},{"line_number":3181,"context_line":"                qemu_img_extra_arg \u003d [commit_top_file]"},{"line_number":3182,"context_line":"                # execute operation with disk concurrency semaphore"},{"line_number":3183,"context_line":"                with compute_utils.disk_ops_semaphore:"},{"line_number":3184,"context_line":"                    processutils.execute(\"qemu-img\", \"commit\", \"-b\", base_file,"},{"line_number":3185,"context_line":"                                         *qemu_img_extra_arg)"},{"line_number":3186,"context_line":""},{"line_number":3187,"context_line":"    def volume_snapshot_delete(self, context, instance, volume_id, snapshot_id,"},{"line_number":3188,"context_line":"                               delete_info):"}],"source_content_type":"text/x-python","patch_set":2,"id":"1aaeeb54_17988363","line":3185,"range":{"start_line":3183,"start_character":0,"end_line":3185,"end_character":61},"updated":"2021-04-22 15:46:20.000000000","message":"So given the following chain this would commit s3 into s2 while the instance still points at s4 right?\n\nbase \u003c- s1 \u003c- s2 \u003c- s3 \u003c- s4 (active)\n\nAt this point don\u0027t you need to rebase s4 on s2 to get the desired chain before we can remove s3?\n\nbase \u003c- s1 \u003c- s2 \u003c- s4 (active)\n\nvirDomainBlockCommit does this for you above but qemu-img commit does not:\n\nhttps://libvirt.org/html/libvirt-libvirt-domain.html#virDomainBlockCommit\n\n\"Commit changes that were made to temporary top-level files within a disk image backing file chain into a lower-level base file. In other words, take all the difference between @base and @top, and update @base to contain that difference; after the commit, any portion of the chain that previously depended on @top will now depend on @base, and all files after @base up to and including @top will now be invalidated. A typical use of this command is to reduce the length of a backing file chain after taking an external disk snapshot. To move data in the opposite direction, see virDomainBlockPull().\"","commit_id":"c404b4d4dea53be59bdaee35afdfe5f12fb12e38"}]}
