)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":14274,"name":"XinXiaohui","email":"xiaohui.xin@intel.com","username":"XinXiaohui"},"change_message_id":"cc2df626a96a28916396670910ee7db09d99a675","unresolved":false,"context_lines":[{"line_number":12,"context_line":"children.  Since delete_snapshot() is asynchronous, the client is not"},{"line_number":13,"context_line":"notified of the situation, and confusion ensues."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"This patch changes the change the delete_snapshot behaviour by hiding"},{"line_number":16,"context_line":"snapshots that have dependent children until the final child volume is"},{"line_number":17,"context_line":"deleted.  Upon final volume deletion, the \u0027pending\u0027 snapshot is then"},{"line_number":18,"context_line":"removed."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"dae33548_af9298f4","line":15,"range":{"start_line":15,"start_character":11,"end_line":15,"end_character":29},"updated":"2016-02-19 08:13:46.000000000","message":"s/changes the change/changes","commit_id":"afa73160166d35f9418f213b7ef9e2e267fea06c"},{"author":{"_account_id":14274,"name":"XinXiaohui","email":"xiaohui.xin@intel.com","username":"XinXiaohui"},"change_message_id":"cc2df626a96a28916396670910ee7db09d99a675","unresolved":false,"context_lines":[{"line_number":20,"context_line":"There are a few benefits to this approach:"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"  1. The user is no longer exposed to RBD implementation details and"},{"line_number":23,"context_line":"     snapshot removal Just Works™"},{"line_number":24,"context_line":"  2. By hiding the snapshot, any volume sharing that the children are"},{"line_number":25,"context_line":"     benefiting from remains intact.  This is why my earlier"},{"line_number":26,"context_line":"     auto-flatten patch was a bad idea."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"dae33548_0f48e486","line":23,"range":{"start_line":23,"start_character":27,"end_line":23,"end_character":32},"updated":"2016-02-19 08:13:46.000000000","message":"Seems there is a special symbol in Works™?","commit_id":"afa73160166d35f9418f213b7ef9e2e267fea06c"},{"author":{"_account_id":10224,"name":"Feodor Tersin","email":"ftersin@hotmail.com","username":"ftersin"},"change_message_id":"1eaa833a8292da4e6231ac6475a0bde319f205c0","unresolved":false,"context_lines":[{"line_number":23,"context_line":"  2. By hiding the snapshot, any volume sharing that the children are"},{"line_number":24,"context_line":"     benefiting from remains intact.  This is why my earlier"},{"line_number":25,"context_line":"     auto-flatten patch was a bad idea."},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"Change-Id: Ic8bcffcb6353401318e371066c641ffe5dd6a7b3"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1a6eadb0_881dd075","line":26,"updated":"2016-12-13 15:39:46.000000000","message":"probably you should refer to bug 1648885 here","commit_id":"51bb34c96cd8265b2fdaa799d4d72b46f10210ff"},{"author":{"_account_id":9236,"name":"Jon Bernard","email":"jobernar@redhat.com","username":"jbernard"},"change_message_id":"397fbaa6aaefc0dce7584205cf4cd4b1572e0649","unresolved":false,"context_lines":[{"line_number":23,"context_line":"  2. By hiding the snapshot, any volume sharing that the children are"},{"line_number":24,"context_line":"     benefiting from remains intact.  This is why my earlier"},{"line_number":25,"context_line":"     auto-flatten patch was a bad idea."},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"Change-Id: Ic8bcffcb6353401318e371066c641ffe5dd6a7b3"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1a6eadb0_417f13aa","line":26,"in_reply_to":"1a6eadb0_881dd075","updated":"2016-12-13 16:44:39.000000000","message":"Will do, thanks.","commit_id":"51bb34c96cd8265b2fdaa799d4d72b46f10210ff"}],"cinder/volume/drivers/rbd.py":[{"author":{"_account_id":20599,"name":"Jason Dillaman","email":"dillaman@redhat.com","username":"dillaman"},"change_message_id":"ce1f358d8a73c73268d54602840cfb3f6b4372a3","unresolved":false,"context_lines":[{"line_number":666,"context_line":"        \"\"\"Return a pending snapshot that should be deleted.\"\"\""},{"line_number":667,"context_line":""},{"line_number":668,"context_line":"        try:"},{"line_number":669,"context_line":"            (pool, parent, snap) \u003d image.parent_info()"},{"line_number":670,"context_line":"        except ValueError:"},{"line_number":671,"context_line":"            return None"},{"line_number":672,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"dae33548_7faeab2e","line":669,"updated":"2016-02-18 14:42:14.000000000","message":"Would this cleanup logic also need to be run pre-flatten?  Create a snapshot, clone from snapshot, delete snapshot (results in new .deleted meta-image), clone the snapshot volume into new volume, flatten parent due to chain length, delete the snapshot volume -- at this point, the volume no longer knows about it\u0027s original parent.","commit_id":"afa73160166d35f9418f213b7ef9e2e267fea06c"},{"author":{"_account_id":9236,"name":"Jon Bernard","email":"jobernar@redhat.com","username":"jbernard"},"change_message_id":"c42670d079a413fe3c5dc49bc4914e96b0770b48","unresolved":false,"context_lines":[{"line_number":666,"context_line":"        \"\"\"Return a pending snapshot that should be deleted.\"\"\""},{"line_number":667,"context_line":""},{"line_number":668,"context_line":"        try:"},{"line_number":669,"context_line":"            (pool, parent, snap) \u003d image.parent_info()"},{"line_number":670,"context_line":"        except ValueError:"},{"line_number":671,"context_line":"            return None"},{"line_number":672,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_61004c02","line":669,"in_reply_to":"dada55a8_dbdc89e6","updated":"2016-07-19 19:57:58.000000000","message":"Wait, I think I\u0027m wrong about that.\n\nSo, in the RBD driver there are two cases where a parent/child relationship is broken:\n\n1. On create volume from snapshot, if flatten_from_snapshot is set, then the volume will be flattened.  This isn\u0027t an issue because the snapshot must already exist, and the flattening will cause a later snapshot delete to skip pending stuff.\n\n2. When max_clone_depth is reached.  This logic is only invoked for volume_from_volume, which I believe cannot effect the pending snapshot logic.  It doesn\u0027t walk backup up the chain, it just checks if the limit is reached and then issues copy() instead of clone().\n\nI /think/ we\u0027re okay.","commit_id":"afa73160166d35f9418f213b7ef9e2e267fea06c"},{"author":{"_account_id":9236,"name":"Jon Bernard","email":"jobernar@redhat.com","username":"jbernard"},"change_message_id":"ed6e6edb65cbf4e17e4dbe147b09aef2318a7928","unresolved":false,"context_lines":[{"line_number":666,"context_line":"        \"\"\"Return a pending snapshot that should be deleted.\"\"\""},{"line_number":667,"context_line":""},{"line_number":668,"context_line":"        try:"},{"line_number":669,"context_line":"            (pool, parent, snap) \u003d image.parent_info()"},{"line_number":670,"context_line":"        except ValueError:"},{"line_number":671,"context_line":"            return None"},{"line_number":672,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_dbdc89e6","line":669,"in_reply_to":"dae33548_7faeab2e","updated":"2016-07-19 19:33:23.000000000","message":"Yep, good point.","commit_id":"afa73160166d35f9418f213b7ef9e2e267fea06c"},{"author":{"_account_id":14274,"name":"XinXiaohui","email":"xiaohui.xin@intel.com","username":"XinXiaohui"},"change_message_id":"cc2df626a96a28916396670910ee7db09d99a675","unresolved":false,"context_lines":[{"line_number":675,"context_line":""},{"line_number":676,"context_line":"        children \u003d []"},{"line_number":677,"context_line":""},{"line_number":678,"context_line":"        try:"},{"line_number":679,"context_line":"            placeholder \u003d self.rbd.Image(client.ioctx, \"%s.deleted\" % snap)"},{"line_number":680,"context_line":"            placeholder.close()"},{"line_number":681,"context_line":"            snapshot \u003d self.rbd.Image(client.ioctx, parent, snapshot\u003dsnap)"},{"line_number":682,"context_line":"            children \u003d snapshot.list_children()"},{"line_number":683,"context_line":"            snapshot.close()"},{"line_number":684,"context_line":"        except self.rbd.ImageNotFound:"},{"line_number":685,"context_line":"            return None"},{"line_number":686,"context_line":""},{"line_number":687,"context_line":"        if len(children) !\u003d 1:"},{"line_number":688,"context_line":"            return None"}],"source_content_type":"text/x-python","patch_set":1,"id":"dae33548_2f0b287f","line":685,"range":{"start_line":678,"start_character":8,"end_line":685,"end_character":23},"updated":"2016-02-19 08:13:46.000000000","message":"Do we need a \"finally\" sentence here? As if any exception is raised, we still need to do volume/snapshot close().","commit_id":"afa73160166d35f9418f213b7ef9e2e267fea06c"},{"author":{"_account_id":20599,"name":"Jason Dillaman","email":"dillaman@redhat.com","username":"dillaman"},"change_message_id":"ce1f358d8a73c73268d54602840cfb3f6b4372a3","unresolved":false,"context_lines":[{"line_number":703,"context_line":""},{"line_number":704,"context_line":"        self.RBDProxy().remove(client.ioctx, \"%s.deleted\" % snapshot)"},{"line_number":705,"context_line":"        with RBDVolumeProxy(self, parent, pool) as volume:"},{"line_number":706,"context_line":"            volume.unprotect_snap(snapshot)"},{"line_number":707,"context_line":"            volume.remove_snap(snapshot)"},{"line_number":708,"context_line":""},{"line_number":709,"context_line":"    def delete_volume(self, volume):"}],"source_content_type":"text/x-python","patch_set":1,"id":"dae33548_1fd31f61","line":706,"updated":"2016-02-18 14:42:14.000000000","message":"Is it possible to create two volumes from the same snapshot?  If so, it could raise an ImageBusy exception here when deleting the first clone.","commit_id":"afa73160166d35f9418f213b7ef9e2e267fea06c"},{"author":{"_account_id":9236,"name":"Jon Bernard","email":"jobernar@redhat.com","username":"jbernard"},"change_message_id":"bb602fd9299b3489f9e2af28fcf8f0e0562a8407","unresolved":false,"context_lines":[{"line_number":703,"context_line":""},{"line_number":704,"context_line":"        self.RBDProxy().remove(client.ioctx, \"%s.deleted\" % snapshot)"},{"line_number":705,"context_line":"        with RBDVolumeProxy(self, parent, pool) as volume:"},{"line_number":706,"context_line":"            volume.unprotect_snap(snapshot)"},{"line_number":707,"context_line":"            volume.remove_snap(snapshot)"},{"line_number":708,"context_line":""},{"line_number":709,"context_line":"    def delete_volume(self, volume):"}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_e03d5bbc","line":706,"in_reply_to":"dae33548_1fd31f61","updated":"2016-07-19 18:34:00.000000000","message":"That case should be caught in _get_pending_snapshot() which will only return a snapshot object if there are no other dependencies.","commit_id":"afa73160166d35f9418f213b7ef9e2e267fea06c"},{"author":{"_account_id":14865,"name":"Adriano Freires Rosso","email":"adriano.rosso@fit-tecnologia.org.br","username":"adriano_rosso"},"change_message_id":"121db1a5ba34c5f8c6ff19150cc7d6e11441600c","unresolved":false,"context_lines":[{"line_number":675,"context_line":""},{"line_number":676,"context_line":"        try:"},{"line_number":677,"context_line":"            (pool, parent, snap) \u003d image.parent_info()"},{"line_number":678,"context_line":"        except self.rbd.ImageNotFound:"},{"line_number":679,"context_line":"            return None"},{"line_number":680,"context_line":"        except ValueError:"},{"line_number":681,"context_line":"            return None"},{"line_number":682,"context_line":""},{"line_number":683,"context_line":"        if not snap:"},{"line_number":684,"context_line":"            return None"}],"source_content_type":"text/x-python","patch_set":3,"id":"9ad45d7e_92d6154d","line":681,"range":{"start_line":678,"start_character":7,"end_line":681,"end_character":23},"updated":"2016-08-11 16:04:51.000000000","message":"Why not use a single except statement since both will return None?\nexcept (self.rbd.ImageNotFound, ValueError):\n    return None","commit_id":"59ea95d8369416cc1d1d6d075d9fd6e72521a947"},{"author":{"_account_id":9236,"name":"Jon Bernard","email":"jobernar@redhat.com","username":"jbernard"},"change_message_id":"5eee6e09b64bde3d76bbd72de55be3be3bc5eeda","unresolved":false,"context_lines":[{"line_number":678,"context_line":"        except self.rbd.ImageNotFound:"},{"line_number":679,"context_line":"            return None"},{"line_number":680,"context_line":"        except ValueError:"},{"line_number":681,"context_line":"            return None"},{"line_number":682,"context_line":""},{"line_number":683,"context_line":"        if not snap:"},{"line_number":684,"context_line":"            return None"}],"source_content_type":"text/x-python","patch_set":3,"id":"9ad45d7e_13ea0674","line":681,"in_reply_to":"9ad45d7e_92d6154d","updated":"2016-08-12 01:30:27.000000000","message":"Because I didn\u0027t know you could do that ;)","commit_id":"59ea95d8369416cc1d1d6d075d9fd6e72521a947"},{"author":{"_account_id":14865,"name":"Adriano Freires Rosso","email":"adriano.rosso@fit-tecnologia.org.br","username":"adriano_rosso"},"change_message_id":"121db1a5ba34c5f8c6ff19150cc7d6e11441600c","unresolved":false,"context_lines":[{"line_number":694,"context_line":"        except self.rbd.ImageNotFound:"},{"line_number":695,"context_line":"            return None"},{"line_number":696,"context_line":""},{"line_number":697,"context_line":"        if len(children) !\u003d 1:"},{"line_number":698,"context_line":"            return None"},{"line_number":699,"context_line":""},{"line_number":700,"context_line":"        (pool, volume) \u003d children[0]"},{"line_number":701,"context_line":"        if volume !\u003d name:"}],"source_content_type":"text/x-python","patch_set":3,"id":"9ad45d7e_92f4555b","line":698,"range":{"start_line":697,"start_character":8,"end_line":698,"end_character":23},"updated":"2016-08-11 16:04:51.000000000","message":"Is it not possible to have more elements in this list? If yes, what is supposed to happen if len(children) \u003d\u003d 2, for example?","commit_id":"59ea95d8369416cc1d1d6d075d9fd6e72521a947"},{"author":{"_account_id":9236,"name":"Jon Bernard","email":"jobernar@redhat.com","username":"jbernard"},"change_message_id":"5eee6e09b64bde3d76bbd72de55be3be3bc5eeda","unresolved":false,"context_lines":[{"line_number":695,"context_line":"            return None"},{"line_number":696,"context_line":""},{"line_number":697,"context_line":"        if len(children) !\u003d 1:"},{"line_number":698,"context_line":"            return None"},{"line_number":699,"context_line":""},{"line_number":700,"context_line":"        (pool, volume) \u003d children[0]"},{"line_number":701,"context_line":"        if volume !\u003d name:"}],"source_content_type":"text/x-python","patch_set":3,"id":"9ad45d7e_9329d69d","line":698,"in_reply_to":"9ad45d7e_92f4555b","updated":"2016-08-12 01:30:27.000000000","message":"I see what you\u0027re saying, readability here is terrible.  I can do better.","commit_id":"59ea95d8369416cc1d1d6d075d9fd6e72521a947"},{"author":{"_account_id":14865,"name":"Adriano Freires Rosso","email":"adriano.rosso@fit-tecnologia.org.br","username":"adriano_rosso"},"change_message_id":"121db1a5ba34c5f8c6ff19150cc7d6e11441600c","unresolved":false,"context_lines":[{"line_number":701,"context_line":"        if volume !\u003d name:"},{"line_number":702,"context_line":"            return None"},{"line_number":703,"context_line":""},{"line_number":704,"context_line":"        return (pool, parent, snap)"},{"line_number":705,"context_line":""},{"line_number":706,"context_line":"    def _delete_pending_snapshot(self, client, pending_snap):"},{"line_number":707,"context_line":"        \"\"\"Delete a pending snapshot when the last volume is deleted.\"\"\""}],"source_content_type":"text/x-python","patch_set":3,"id":"9ad45d7e_b22fd93d","line":704,"range":{"start_line":704,"start_character":8,"end_line":704,"end_character":35},"updated":"2016-08-11 16:04:51.000000000","message":"Parentheses are not needed.","commit_id":"59ea95d8369416cc1d1d6d075d9fd6e72521a947"},{"author":{"_account_id":9236,"name":"Jon Bernard","email":"jobernar@redhat.com","username":"jbernard"},"change_message_id":"5eee6e09b64bde3d76bbd72de55be3be3bc5eeda","unresolved":false,"context_lines":[{"line_number":701,"context_line":"        if volume !\u003d name:"},{"line_number":702,"context_line":"            return None"},{"line_number":703,"context_line":""},{"line_number":704,"context_line":"        return (pool, parent, snap)"},{"line_number":705,"context_line":""},{"line_number":706,"context_line":"    def _delete_pending_snapshot(self, client, pending_snap):"},{"line_number":707,"context_line":"        \"\"\"Delete a pending snapshot when the last volume is deleted.\"\"\""}],"source_content_type":"text/x-python","patch_set":3,"id":"9ad45d7e_f31ad27b","line":704,"in_reply_to":"9ad45d7e_b22fd93d","updated":"2016-08-12 01:30:27.000000000","message":"Ok, thanks.","commit_id":"59ea95d8369416cc1d1d6d075d9fd6e72521a947"},{"author":{"_account_id":10224,"name":"Feodor Tersin","email":"ftersin@hotmail.com","username":"ftersin"},"change_message_id":"368eaa1c05f48a05ad9b7f7f204fe6c774f56f31","unresolved":false,"context_lines":[{"line_number":770,"context_line":"                placeholder \u003d \"%s.deleted\" % snap_name"},{"line_number":771,"context_line":"                with RADOSClient(self) as client:"},{"line_number":772,"context_line":"                    self.RBDProxy().create(client.ioctx, placeholder, 0, 0)"},{"line_number":773,"context_line":"                return"},{"line_number":774,"context_line":"            try:"},{"line_number":775,"context_line":"                volume.remove_snap(snap_name)"},{"line_number":776,"context_line":"            except self.rbd.ImageNotFound:"}],"source_content_type":"text/x-python","patch_set":6,"id":"1a6eadb0_ac8fe0ca","line":773,"updated":"2016-12-14 07:08:01.000000000","message":"Could we have a logging here to make sure this code works during CI at least? Since bug 1648885 happens randomly, we need to have explicit evidence that this patch helps.","commit_id":"ba9e0f9ae7109bdc321d07832e073e4b3e849ab6"},{"author":{"_account_id":19901,"name":"Xu Ao","email":"xuao@awcloud.com","username":"xuao"},"change_message_id":"dc6fe8e86f7812867823d0f81765b22713df82a8","unresolved":false,"context_lines":[{"line_number":621,"context_line":"        children \u003d []"},{"line_number":622,"context_line":""},{"line_number":623,"context_line":"        try:"},{"line_number":624,"context_line":"            placeholder \u003d self.rbd.Image(client.ioctx, \"%s.deleted\" % snap)"},{"line_number":625,"context_line":"            placeholder.close()"},{"line_number":626,"context_line":"            snapshot \u003d self.rbd.Image(client.ioctx, parent, snapshot\u003dsnap)"},{"line_number":627,"context_line":"            children \u003d snapshot.list_children()"}],"source_content_type":"text/x-python","patch_set":7,"id":"1a6eadb0_7e50980b","line":624,"range":{"start_line":624,"start_character":12,"end_line":624,"end_character":75},"updated":"2016-12-16 07:01:33.000000000","message":"I\u0027m sorry for my mistake. The judgement has been made here whether the placeholer exist or not.","commit_id":"b90016519a126609aad0df09f0542494e20c6d8a"},{"author":{"_account_id":19901,"name":"Xu Ao","email":"xuao@awcloud.com","username":"xuao"},"change_message_id":"bc3e5cb3847e350c6c3434e8c13547aada592512","unresolved":false,"context_lines":[{"line_number":630,"context_line":"            return None"},{"line_number":631,"context_line":""},{"line_number":632,"context_line":"        # Are there other dependent volumes besides this one?"},{"line_number":633,"context_line":"        if len(children) !\u003d 1:"},{"line_number":634,"context_line":"            return None"},{"line_number":635,"context_line":""},{"line_number":636,"context_line":"        # Sanity check, one dependent volume should be exactly this one."}],"source_content_type":"text/x-python","patch_set":7,"id":"1a6eadb0_0a3319f7","line":633,"range":{"start_line":633,"start_character":8,"end_line":633,"end_character":30},"updated":"2016-12-15 07:10:44.000000000","message":"I am convinced by your consummate solution. IMO,while the snapshot only have \"1 children\" \u0026\u0026 \"have been asked to deleted\"(have a placeholder with its id), then it will be removed.","commit_id":"b90016519a126609aad0df09f0542494e20c6d8a"},{"author":{"_account_id":9236,"name":"Jon Bernard","email":"jobernar@redhat.com","username":"jbernard"},"change_message_id":"e0916f40306e6ae66a145ac027b6dd0bbe1f402e","unresolved":false,"context_lines":[{"line_number":630,"context_line":"            return None"},{"line_number":631,"context_line":""},{"line_number":632,"context_line":"        # Are there other dependent volumes besides this one?"},{"line_number":633,"context_line":"        if len(children) !\u003d 1:"},{"line_number":634,"context_line":"            return None"},{"line_number":635,"context_line":""},{"line_number":636,"context_line":"        # Sanity check, one dependent volume should be exactly this one."}],"source_content_type":"text/x-python","patch_set":7,"id":"1a6eadb0_1b3988f2","line":633,"in_reply_to":"1a6eadb0_0a3319f7","updated":"2016-12-15 19:40:16.000000000","message":"I don\u0027t quite follow, can you elaboarate a bit?","commit_id":"b90016519a126609aad0df09f0542494e20c6d8a"},{"author":{"_account_id":4523,"name":"Eric Harney","email":"eharney@redhat.com","username":"eharney"},"change_message_id":"ce223851658fe4dfa697bd32a979e4aafa9afb33","unresolved":false,"context_lines":[{"line_number":1220,"context_line":"                # cannot rename a snapshot (until infernalis), so we create an"},{"line_number":1221,"context_line":"                # image with the same name as the snapshot with \u0027.deleted\u0027"},{"line_number":1222,"context_line":"                # suffix as a placeholder"},{"line_number":1223,"context_line":"                LOG.info(_LI(\"ImageBusy: Snapshot %s has dependent volumes, \""},{"line_number":1224,"context_line":"                             \"postponing deletion.\"), snap_name)"},{"line_number":1225,"context_line":"                placeholder \u003d \"%s.deleted\" % snap_name"},{"line_number":1226,"context_line":"                with RADOSClient(self) as client:"}],"source_content_type":"text/x-python","patch_set":9,"id":"9fb8cfa7_09253bab","line":1223,"range":{"start_line":1223,"start_character":25,"end_line":1223,"end_character":28},"updated":"2019-06-10 14:08:05.000000000","message":"No more _LI","commit_id":"bbff28a45a1e14410939d78d65f3cbdabfb2e72e"}]}
