)]}'
{"nova/virt/block_device.py":[{"author":{"_account_id":10135,"name":"Lee Yarwood","display_name":"Lee Yarwood","email":"lyarwood@redhat.com","username":"lyarwood"},"change_message_id":"6e9da33a82642ca14b24825b4d3a27c243c9b150","unresolved":false,"context_lines":[{"line_number":375,"context_line":"        self._preserve_multipath_id(connection_info)"},{"line_number":376,"context_line":"        if self.volume_size is None:"},{"line_number":377,"context_line":"            self.volume_size \u003d volume.get(\u0027size\u0027)"},{"line_number":378,"context_line":"        self.connection_info \u003d connection_info"},{"line_number":379,"context_line":""},{"line_number":380,"context_line":"        # If do_driver_attach is False, we will attach a volume to an instance"},{"line_number":381,"context_line":"        # at boot time. So actual attach is done by instance creation code."}],"source_content_type":"text/x-python","patch_set":2,"id":"df87a7cf_6df06968","line":378,"range":{"start_line":378,"start_character":8,"end_line":378,"end_character":46},"updated":"2017-12-19 10:03:27.000000000","message":"Any reason not to set this on L370 and then use self.connection_info below?","commit_id":"20a880d723c1ce7ca71e68c4a370b6e1f18c6d81"},{"author":{"_account_id":9555,"name":"Matthew Booth","email":"mbooth@redhat.com","username":"MatthewBooth"},"change_message_id":"60dfd037d2666b57f53120c7c26f46974fbb8d93","unresolved":false,"context_lines":[{"line_number":375,"context_line":"        self._preserve_multipath_id(connection_info)"},{"line_number":376,"context_line":"        if self.volume_size is None:"},{"line_number":377,"context_line":"            self.volume_size \u003d volume.get(\u0027size\u0027)"},{"line_number":378,"context_line":"        self.connection_info \u003d connection_info"},{"line_number":379,"context_line":""},{"line_number":380,"context_line":"        # If do_driver_attach is False, we will attach a volume to an instance"},{"line_number":381,"context_line":"        # at boot time. So actual attach is done by instance creation code."}],"source_content_type":"text/x-python","patch_set":2,"id":"df87a7cf_106776eb","line":378,"range":{"start_line":378,"start_character":8,"end_line":378,"end_character":46},"in_reply_to":"df87a7cf_6df06968","updated":"2017-12-19 10:11:02.000000000","message":"Agree this would be cleaner. The only reason is to reduce noise in an already noisy patch, tbh.","commit_id":"20a880d723c1ce7ca71e68c4a370b6e1f18c6d81"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"cb2b9a0c5ce56e3837bf9438f01a9a44c6634fe1","unresolved":false,"context_lines":[{"line_number":584,"context_line":"        # TODO(mriedem): Technically for the new flow, we shouldn\u0027t have to"},{"line_number":585,"context_line":"        # rely on the BlockDeviceMapping.connection_info since it\u0027s stored"},{"line_number":586,"context_line":"        # with the attachment in Cinder (see refresh_connection_info)."},{"line_number":587,"context_line":"        # Therefore we should phase out code that relies on the"},{"line_number":588,"context_line":"        # BDM.connection_info and get it from Cinder if it\u0027s needed."},{"line_number":589,"context_line":"        self.save()"},{"line_number":590,"context_line":""},{"line_number":591,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":15,"id":"5f7c97a3_660f7ce1","line":588,"range":{"start_line":587,"start_character":8,"end_line":588,"end_character":68},"updated":"2018-05-07 20:09:29.000000000","message":"Seems that this comment is incongruent with this patch. This patch is essentially always saving the connection_info in the DriverBlockDevice object with the purpose of allowing drivers to use this information later on. While the comment suggests we should *not* be doing that and should phase out BDM.connection_info entirely.\n\nWhich is correct?","commit_id":"1de344b1a00eb09ee1b7e96076c93bb1d635080d"},{"author":{"_account_id":9555,"name":"Matthew Booth","email":"mbooth@redhat.com","username":"MatthewBooth"},"change_message_id":"9b85b8ac51a7828395cd80713119a0c496ca213a","unresolved":false,"context_lines":[{"line_number":584,"context_line":"        # TODO(mriedem): Technically for the new flow, we shouldn\u0027t have to"},{"line_number":585,"context_line":"        # rely on the BlockDeviceMapping.connection_info since it\u0027s stored"},{"line_number":586,"context_line":"        # with the attachment in Cinder (see refresh_connection_info)."},{"line_number":587,"context_line":"        # Therefore we should phase out code that relies on the"},{"line_number":588,"context_line":"        # BDM.connection_info and get it from Cinder if it\u0027s needed."},{"line_number":589,"context_line":"        self.save()"},{"line_number":590,"context_line":""},{"line_number":591,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":15,"id":"5f7c97a3_75a7f650","line":588,"range":{"start_line":587,"start_character":8,"end_line":588,"end_character":68},"in_reply_to":"5f7c97a3_660f7ce1","updated":"2018-05-09 17:00:26.000000000","message":"Matt\u0027s comment is still correct, but there\u0027s a bunch of work to be done before we get there. For example, we still mutate connection_info with local state on attach, which we obviously can\u0027t re-fetch from cinder because cinder doesn\u0027t have it. This is dirty and un-natural, but it\u0027s one of the things which we need to unpick before we drop connection_info locally. That work is going to require its own spec.\n\nThis change doesn\u0027t affect that. connection_info is still stored in the BDM, we still need to pass it to attach_volume, and it\u0027s still stashed in this object following this call. We previously set self[\u0027connection_info\u0027] immediately before calling save, but now we set it on line 561 instead because it needs to be set before calling attach_volume. We also set it as an attribute rather than a dict item now, but the effect is the same because of change I35ebff9a.","commit_id":"1de344b1a00eb09ee1b7e96076c93bb1d635080d"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"48d0fb1c735dec22e6eb946d884d7d6f353b75ec","unresolved":false,"context_lines":[{"line_number":584,"context_line":"        # TODO(mriedem): Technically for the new flow, we shouldn\u0027t have to"},{"line_number":585,"context_line":"        # rely on the BlockDeviceMapping.connection_info since it\u0027s stored"},{"line_number":586,"context_line":"        # with the attachment in Cinder (see refresh_connection_info)."},{"line_number":587,"context_line":"        # Therefore we should phase out code that relies on the"},{"line_number":588,"context_line":"        # BDM.connection_info and get it from Cinder if it\u0027s needed."},{"line_number":589,"context_line":"        self.save()"},{"line_number":590,"context_line":""},{"line_number":591,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":15,"id":"5f7c97a3_83ddb871","line":588,"range":{"start_line":587,"start_character":8,"end_line":588,"end_character":68},"in_reply_to":"5f7c97a3_75a7f650","updated":"2018-05-09 17:04:40.000000000","message":"\u003e For example, we still mutate connection_info with local state on attach, which we obviously can\u0027t re-fetch from cinder because cinder doesn\u0027t have it. This is dirty and un-natural, but it\u0027s one of the things which we need to unpick before we drop connection_info locally. That work is going to require its own spec.\n\nThe three cases I can think of for this are:\n\n1. The device_path set by the virt driver and used by the volume drivers.\n2. The serial key (used by the libvirt driver, put into the block device disk config element).\n3. The multiattach flag, also used by the libvirt volume driver to set the \u0027shareable\u0027 flag on the block device disk config element.\n\nSo yeah, unwinding that from stashing it in connection_info and stashing that in the BDM object is a long slog that we haven\u0027t attempted yet.","commit_id":"1de344b1a00eb09ee1b7e96076c93bb1d635080d"}]}
