)]}'
{"nova/cells/manager.py":[{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"9a5ebd27694d0f70f1b37ce05a4bc77f911a1b36","unresolved":false,"context_lines":[{"line_number":64,"context_line":""},{"line_number":65,"context_line":"    Scheduling requests get passed to the scheduler class."},{"line_number":66,"context_line":"    \"\"\""},{"line_number":67,"context_line":"    RPC_API_VERSION \u003d \u00271.8\u0027"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"    def __init__(self, *args, **kwargs):"},{"line_number":70,"context_line":"        # Mostly for tests."}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAPX%2F%2F8aE%3D","line":67,"updated":"2013-06-05 15:58:27.000000000","message":"Need to bump since laski\u0027s patch landed","commit_id":"e50369b27d0c31e53a5a175cf3ee0c3e8440e6af"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"9a5ebd27694d0f70f1b37ce05a4bc77f911a1b36","unresolved":false,"context_lines":[{"line_number":380,"context_line":"                console_type)"},{"line_number":381,"context_line":"        return response.value_or_raise()"},{"line_number":382,"context_line":""},{"line_number":383,"context_line":"    def bdm_update_or_create_at_top(self, ctxt, bdm, create\u003dNone):"},{"line_number":384,"context_line":"        \"\"\"BDM was created/updated in this cell.  Tell the API cells.\"\"\""},{"line_number":385,"context_line":"        self.msg_runner.bdm_update_or_create_at_top(ctxt, bdm, create\u003dcreate)"},{"line_number":386,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAPX%2F%2F8aA%3D","line":383,"updated":"2013-06-05 15:58:27.000000000","message":"This is a lot clearer with the renames, thx.","commit_id":"e50369b27d0c31e53a5a175cf3ee0c3e8440e6af"}],"nova/cells/messaging.py":[{"author":{"_account_id":5652,"name":"David Ripton","email":"dripton@redhat.com","username":"dripton"},"change_message_id":"71a10d50342d15834209903c9c448bb73b3c2c42","unresolved":false,"context_lines":[{"line_number":965,"context_line":"        update but fall back to create.  If create is False, only attempt"},{"line_number":966,"context_line":"        to update.  This maps to nova-conductor\u0027s behavior."},{"line_number":967,"context_line":"        \"\"\""},{"line_number":968,"context_line":"        if not self._at_the_top():"},{"line_number":969,"context_line":"            return"},{"line_number":970,"context_line":"        items_to_remove \u003d [\u0027id\u0027]"},{"line_number":971,"context_line":"        for key in items_to_remove:"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAPX%2F%2F2Mc%3D","line":968,"updated":"2013-06-07 17:24:01.000000000","message":"Maybe this should be mentioned in the docstring.","commit_id":"c0237c9fb1439ead034e923582e7bf39776ef6d3"},{"author":{"_account_id":1030,"name":"Chris Behrens","email":"cbehrens@codestud.com","username":"cbehrens"},"change_message_id":"df1cad1301be69003c18db7afea24296bef0a7d8","unresolved":false,"context_lines":[{"line_number":965,"context_line":"        update but fall back to create.  If create is False, only attempt"},{"line_number":966,"context_line":"        to update.  This maps to nova-conductor\u0027s behavior."},{"line_number":967,"context_line":"        \"\"\""},{"line_number":968,"context_line":"        if not self._at_the_top():"},{"line_number":969,"context_line":"            return"},{"line_number":970,"context_line":"        items_to_remove \u003d [\u0027id\u0027]"},{"line_number":971,"context_line":"        for key in items_to_remove:"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAPX%2F%2Fl%2BQ%3D","line":968,"in_reply_to":"AAAAPX%2F%2F2Mc%3D","updated":"2013-06-14 19:26:25.000000000","message":"It is: \"update in API cell\".  And it\u0027s clear in the method name.  ??","commit_id":"c0237c9fb1439ead034e923582e7bf39776ef6d3"},{"author":{"_account_id":5652,"name":"David Ripton","email":"dripton@redhat.com","username":"dripton"},"change_message_id":"71a10d50342d15834209903c9c448bb73b3c2c42","unresolved":false,"context_lines":[{"line_number":1001,"context_line":"        \"\"\"Destroy a block device mapping in API cells by device name"},{"line_number":1002,"context_line":"        or volume_id.  device_name or volume_id can be None, but not both."},{"line_number":1003,"context_line":"        \"\"\""},{"line_number":1004,"context_line":"        if not self._at_the_top():"},{"line_number":1005,"context_line":"            return"},{"line_number":1006,"context_line":"        if device_name:"},{"line_number":1007,"context_line":"            self.db.block_device_mapping_destroy_by_instance_and_device("}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAPX%2F%2F2ME%3D","line":1004,"updated":"2013-06-07 17:24:01.000000000","message":"In the docstring?","commit_id":"c0237c9fb1439ead034e923582e7bf39776ef6d3"},{"author":{"_account_id":1030,"name":"Chris Behrens","email":"cbehrens@codestud.com","username":"cbehrens"},"change_message_id":"df1cad1301be69003c18db7afea24296bef0a7d8","unresolved":false,"context_lines":[{"line_number":1001,"context_line":"        \"\"\"Destroy a block device mapping in API cells by device name"},{"line_number":1002,"context_line":"        or volume_id.  device_name or volume_id can be None, but not both."},{"line_number":1003,"context_line":"        \"\"\""},{"line_number":1004,"context_line":"        if not self._at_the_top():"},{"line_number":1005,"context_line":"            return"},{"line_number":1006,"context_line":"        if device_name:"},{"line_number":1007,"context_line":"            self.db.block_device_mapping_destroy_by_instance_and_device("}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAPX%2F%2Fl%2BM%3D","line":1004,"in_reply_to":"AAAAPX%2F%2F2ME%3D","updated":"2013-06-14 19:26:25.000000000","message":"Same.  Maybe the confusion is because there\u0027s a mix of use of \"API cell\" and \"top level cell\" in all docstrings in this file.  I\u0027d rather clean all of that up separately.\n\nFor the purposes of this patch, it\u0027s pretty clear because of \"at_top\" in the method names.","commit_id":"c0237c9fb1439ead034e923582e7bf39776ef6d3"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"e5a2727bff1570cb2f4f22fbecd94efed316e0be","unresolved":false,"context_lines":[{"line_number":1013,"context_line":"        elif volume_id:"},{"line_number":1014,"context_line":"            self.db.block_device_mapping_destroy_by_instance_and_volume("},{"line_number":1015,"context_line":"                    message.ctxt, instance_uuid, volume_id)"},{"line_number":1016,"context_line":""},{"line_number":1017,"context_line":""},{"line_number":1018,"context_line":"_CELL_MESSAGE_TYPE_TO_MESSAGE_CLS \u003d {\u0027targeted\u0027: _TargetedMessage,"},{"line_number":1019,"context_line":"                                     \u0027broadcast\u0027: _BroadcastMessage,"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAPn%2F%2Ft%2BI%3D","line":1016,"updated":"2013-06-24 16:13:26.000000000","message":"Might be good to log if device_name and volume_id are None","commit_id":"39e8f5bd3bc976603c5a0a2dd4ada3dd6b79258d"}],"nova/cells/rpcapi.py":[{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"6ce9c12d82453812929c250562bffddc8a13d0e9","unresolved":false,"context_lines":[{"line_number":282,"context_line":"                              console_type\u003dconsole_type),"},{"line_number":283,"context_line":"                version\u003d\u00271.6\u0027)"},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"    def bdm_update_or_create(self, ctxt, bdm, create\u003dNone):"},{"line_number":286,"context_line":"        \"\"\"Create or update a block device mapping in API cells.  If"},{"line_number":287,"context_line":"        create is True, only try to create.  If create is None, try to"},{"line_number":288,"context_line":"        update but fall back to create.  If create is False, only attempt"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2BiU%3D","line":285,"updated":"2013-06-04 18:48:36.000000000","message":"I think I prefer the _update_at_top naming suffix. :)\n\nSomething like bdm_update_at_top and bdm_destroy_at_top make things obvious for lazy readers like me. :)","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"},{"author":{"_account_id":1030,"name":"Chris Behrens","email":"cbehrens@codestud.com","username":"cbehrens"},"change_message_id":"fb54f29cbb89d59011d4772bfec138d139369728","unresolved":false,"context_lines":[{"line_number":282,"context_line":"                              console_type\u003dconsole_type),"},{"line_number":283,"context_line":"                version\u003d\u00271.6\u0027)"},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"    def bdm_update_or_create(self, ctxt, bdm, create\u003dNone):"},{"line_number":286,"context_line":"        \"\"\"Create or update a block device mapping in API cells.  If"},{"line_number":287,"context_line":"        create is True, only try to create.  If create is None, try to"},{"line_number":288,"context_line":"        update but fall back to create.  If create is False, only attempt"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2Bfw%3D","line":285,"in_reply_to":"AAAAPX%2F%2F%2BiU%3D","updated":"2013-06-04 18:57:25.000000000","message":"Yeah, I was considering fixing all of that up to match.  This code pre-existed in a different form before I re-did cells and used the \u0027at_top\u0027 suffixes.  I\u0027ll go ahead and fix :)","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"9a5ebd27694d0f70f1b37ce05a4bc77f911a1b36","unresolved":false,"context_lines":[{"line_number":52,"context_line":"              action_events_get()"},{"line_number":53,"context_line":"        1.6 - Adds consoleauth_delete_tokens() and validate_console_port()"},{"line_number":54,"context_line":"        1.7 - Adds service_update()"},{"line_number":55,"context_line":"        1.8 - Adds bdm_update_or_create_at_top(), and bdm_destroy_at_top()"},{"line_number":56,"context_line":"    \u0027\u0027\u0027"},{"line_number":57,"context_line":"    BASE_RPC_API_VERSION \u003d \u00271.0\u0027"},{"line_number":58,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAPX%2F%2F8aU%3D","line":55,"updated":"2013-06-05 15:58:27.000000000","message":"Need to bump since laski\u0027s patch landed","commit_id":"e50369b27d0c31e53a5a175cf3ee0c3e8440e6af"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"9a5ebd27694d0f70f1b37ce05a4bc77f911a1b36","unresolved":false,"context_lines":[{"line_number":293,"context_line":"        try:"},{"line_number":294,"context_line":"            self.cast(ctxt, self.make_msg(\u0027bdm_update_or_create_at_top\u0027,"},{"line_number":295,"context_line":"                                          bdm\u003dbdm, create\u003dcreate),"},{"line_number":296,"context_line":"                      version\u003d\u00271.8\u0027)"},{"line_number":297,"context_line":"        except Exception:"},{"line_number":298,"context_line":"            LOG.exception(_(\"Failed to notify cells of BDM update/create.\"))"},{"line_number":299,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAPX%2F%2F8aQ%3D","line":296,"updated":"2013-06-05 15:58:27.000000000","message":"Need to bump since laski\u0027s patch landed","commit_id":"e50369b27d0c31e53a5a175cf3ee0c3e8440e6af"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"9a5ebd27694d0f70f1b37ce05a4bc77f911a1b36","unresolved":false,"context_lines":[{"line_number":295,"context_line":"                                          bdm\u003dbdm, create\u003dcreate),"},{"line_number":296,"context_line":"                      version\u003d\u00271.8\u0027)"},{"line_number":297,"context_line":"        except Exception:"},{"line_number":298,"context_line":"            LOG.exception(_(\"Failed to notify cells of BDM update/create.\"))"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"    def bdm_destroy_at_top(self, ctxt, instance_uuid, device_name\u003dNone,"},{"line_number":301,"context_line":"                           volume_id\u003dNone):"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAPX%2F%2F8Y0%3D","line":298,"updated":"2013-06-05 15:58:27.000000000","message":"Do BDMs need a healing process for cases like this?","commit_id":"e50369b27d0c31e53a5a175cf3ee0c3e8440e6af"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"9a5ebd27694d0f70f1b37ce05a4bc77f911a1b36","unresolved":false,"context_lines":[{"line_number":309,"context_line":"                                          instance_uuid\u003dinstance_uuid,"},{"line_number":310,"context_line":"                                          device_name\u003ddevice_name,"},{"line_number":311,"context_line":"                                          volume_id\u003dvolume_id),"},{"line_number":312,"context_line":"                      version\u003d\u00271.8\u0027)"},{"line_number":313,"context_line":"        except Exception:"},{"line_number":314,"context_line":"            LOG.exception(_(\"Failed to notify cells of BDM destroy.\"))"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAPX%2F%2F8aM%3D","line":312,"updated":"2013-06-05 15:58:27.000000000","message":"Need to bump since laski\u0027s patch landed","commit_id":"e50369b27d0c31e53a5a175cf3ee0c3e8440e6af"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"9a5ebd27694d0f70f1b37ce05a4bc77f911a1b36","unresolved":false,"context_lines":[{"line_number":311,"context_line":"                                          volume_id\u003dvolume_id),"},{"line_number":312,"context_line":"                      version\u003d\u00271.8\u0027)"},{"line_number":313,"context_line":"        except Exception:"},{"line_number":314,"context_line":"            LOG.exception(_(\"Failed to notify cells of BDM destroy.\"))"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAPX%2F%2F8Ys%3D","line":314,"updated":"2013-06-05 15:58:27.000000000","message":"Do BDMs need a healing process for cases like this?","commit_id":"e50369b27d0c31e53a5a175cf3ee0c3e8440e6af"}],"nova/compute/cells_api.py":[{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"6ce9c12d82453812929c250562bffddc8a13d0e9","unresolved":false,"context_lines":[{"line_number":515,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":516,"context_line":"                self.db.block_device_mapping_destroy_by_instance_and_device("},{"line_number":517,"context_line":"                        context, instance[\u0027uuid\u0027], device)"},{"line_number":518,"context_line":"        return self._call_to_cells(context, instance, \u0027attach_volume\u0027,"},{"line_number":519,"context_line":"                volume_id, device)"},{"line_number":520,"context_line":""},{"line_number":521,"context_line":"    @validate_cell"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2Bi4%3D","line":518,"updated":"2013-06-04 18:48:36.000000000","message":"I don\u0027t understand why call is required?  I don\u0027t see any return values in the compute rpcapi this gets proxied to?","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"},{"author":{"_account_id":1030,"name":"Chris Behrens","email":"cbehrens@codestud.com","username":"cbehrens"},"change_message_id":"fb54f29cbb89d59011d4772bfec138d139369728","unresolved":false,"context_lines":[{"line_number":515,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":516,"context_line":"                self.db.block_device_mapping_destroy_by_instance_and_device("},{"line_number":517,"context_line":"                        context, instance[\u0027uuid\u0027], device)"},{"line_number":518,"context_line":"        return self._call_to_cells(context, instance, \u0027attach_volume\u0027,"},{"line_number":519,"context_line":"                volume_id, device)"},{"line_number":520,"context_line":""},{"line_number":521,"context_line":"    @validate_cell"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2Bfg%3D","line":518,"in_reply_to":"AAAAPX%2F%2F%2Bi4%3D","updated":"2013-06-04 18:57:25.000000000","message":"This proxies to compute/api.py\u0027s attach_volume() which returns the device that it found available... in the case that \u0027device\u0027 was None to begin with.  nova/api code uses the response.","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"}],"nova/conductor/manager.py":[{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"6ce9c12d82453812929c250562bffddc8a13d0e9","unresolved":false,"context_lines":[{"line_number":260,"context_line":"                                              create\u003dNone):"},{"line_number":261,"context_line":"        if create is None:"},{"line_number":262,"context_line":"            self.db.block_device_mapping_update_or_create(context, values)"},{"line_number":263,"context_line":"            bdm \u003d values"},{"line_number":264,"context_line":"        elif create is True:"},{"line_number":265,"context_line":"            self.db.block_device_mapping_create(context, values)"},{"line_number":266,"context_line":"            bdm \u003d values"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2BhY%3D","line":263,"updated":"2013-06-04 18:48:36.000000000","message":"Seems awkward that the block_device db methods don\u0027t have a consistent return value, but that\u0027s nothing introduced by this patch.","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"},{"author":{"_account_id":1030,"name":"Chris Behrens","email":"cbehrens@codestud.com","username":"cbehrens"},"change_message_id":"fb54f29cbb89d59011d4772bfec138d139369728","unresolved":false,"context_lines":[{"line_number":260,"context_line":"                                              create\u003dNone):"},{"line_number":261,"context_line":"        if create is None:"},{"line_number":262,"context_line":"            self.db.block_device_mapping_update_or_create(context, values)"},{"line_number":263,"context_line":"            bdm \u003d values"},{"line_number":264,"context_line":"        elif create is True:"},{"line_number":265,"context_line":"            self.db.block_device_mapping_create(context, values)"},{"line_number":266,"context_line":"            bdm \u003d values"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2Bfc%3D","line":263,"in_reply_to":"AAAAPX%2F%2F%2BhY%3D","updated":"2013-06-04 18:57:25.000000000","message":"Believe me, this drives me nuts.","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"6ce9c12d82453812929c250562bffddc8a13d0e9","unresolved":false,"context_lines":[{"line_number":281,"context_line":"        if bdms is not None:"},{"line_number":282,"context_line":"            for bdm in bdms:"},{"line_number":283,"context_line":"                self.db.block_device_mapping_destroy(context, bdm[\u0027id\u0027])"},{"line_number":284,"context_line":"                # NOTE(comstud): bdm[\u0027id\u0027] will be different in API cell,"},{"line_number":285,"context_line":"                # so we must try to destroy by device_name or volume_id."},{"line_number":286,"context_line":"                if not bdm.get(\u0027instance_uuid\u0027):"},{"line_number":287,"context_line":"                    continue"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2Bgs%3D","line":284,"updated":"2013-06-04 18:48:36.000000000","message":"I wonder if BDM should get a UUID to make it easier to compare child and parent values.\n\nI guess some combination of attached instance, device name, and volume id does the trick though...Hmm.","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"},{"author":{"_account_id":1030,"name":"Chris Behrens","email":"cbehrens@codestud.com","username":"cbehrens"},"change_message_id":"fb54f29cbb89d59011d4772bfec138d139369728","unresolved":false,"context_lines":[{"line_number":281,"context_line":"        if bdms is not None:"},{"line_number":282,"context_line":"            for bdm in bdms:"},{"line_number":283,"context_line":"                self.db.block_device_mapping_destroy(context, bdm[\u0027id\u0027])"},{"line_number":284,"context_line":"                # NOTE(comstud): bdm[\u0027id\u0027] will be different in API cell,"},{"line_number":285,"context_line":"                # so we must try to destroy by device_name or volume_id."},{"line_number":286,"context_line":"                if not bdm.get(\u0027instance_uuid\u0027):"},{"line_number":287,"context_line":"                    continue"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2BfM%3D","line":284,"in_reply_to":"AAAAPX%2F%2F%2Bgs%3D","updated":"2013-06-04 18:57:25.000000000","message":"I had the same thoughts.  I think that device_name alone should really do it, though.  But ya.  I\u0027m going to work on moving BDM stuff to objects here RSN.  And I *hope* that I can clean up this mess at that time.","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"6ce9c12d82453812929c250562bffddc8a13d0e9","unresolved":false,"context_lines":[{"line_number":285,"context_line":"                # so we must try to destroy by device_name or volume_id."},{"line_number":286,"context_line":"                if not bdm.get(\u0027instance_uuid\u0027):"},{"line_number":287,"context_line":"                    continue"},{"line_number":288,"context_line":"                if bdm.get(\u0027device_name\u0027):"},{"line_number":289,"context_line":"                    self.cells_rpcapi.bdm_destroy("},{"line_number":290,"context_line":"                            context, bdm[\u0027instance_uuid\u0027],"},{"line_number":291,"context_line":"                            device_name\u003dbdm[\u0027device_name\u0027])"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2Bio%3D","line":288,"updated":"2013-06-04 18:48:36.000000000","message":"Is device_name optional on a BDM?  It says nullable\u003dFalse on the model.","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"},{"author":{"_account_id":1030,"name":"Chris Behrens","email":"cbehrens@codestud.com","username":"cbehrens"},"change_message_id":"fb54f29cbb89d59011d4772bfec138d139369728","unresolved":false,"context_lines":[{"line_number":285,"context_line":"                # so we must try to destroy by device_name or volume_id."},{"line_number":286,"context_line":"                if not bdm.get(\u0027instance_uuid\u0027):"},{"line_number":287,"context_line":"                    continue"},{"line_number":288,"context_line":"                if bdm.get(\u0027device_name\u0027):"},{"line_number":289,"context_line":"                    self.cells_rpcapi.bdm_destroy("},{"line_number":290,"context_line":"                            context, bdm[\u0027instance_uuid\u0027],"},{"line_number":291,"context_line":"                            device_name\u003dbdm[\u0027device_name\u0027])"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAPX%2F%2F%2BfE%3D","line":288,"in_reply_to":"AAAAPX%2F%2F%2Bio%3D","updated":"2013-06-04 18:57:25.000000000","message":"This is mostly for tests... otherwise I would use bdm[\u0027device_name\u0027], even.  I can look at what it takes to fix everything so that this looks better.","commit_id":"1b8ac810070d31068a7cbe3c5db633aad88cf858"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"9a5ebd27694d0f70f1b37ce05a4bc77f911a1b36","unresolved":false,"context_lines":[{"line_number":282,"context_line":"        if bdms is not None:"},{"line_number":283,"context_line":"            for bdm in bdms:"},{"line_number":284,"context_line":"                self.db.block_device_mapping_destroy(context, bdm[\u0027id\u0027])"},{"line_number":285,"context_line":"                # NOTE(comstud): bdm[\u0027id\u0027] will be different in API cell,"},{"line_number":286,"context_line":"                # so we must try to destroy by device_name or volume_id."},{"line_number":287,"context_line":"                # We need an instance_uuid in order to do this properly,"},{"line_number":288,"context_line":"                # too."}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAPX%2F%2F8ZE%3D","line":285,"updated":"2013-06-05 15:58:27.000000000","message":"I think we both agree this code is a little nuts, but cleaning it up can be punted to defining an actual object over the DB model.","commit_id":"e50369b27d0c31e53a5a175cf3ee0c3e8440e6af"}],"nova/db/sqlalchemy/api.py":[{"author":{"_account_id":5652,"name":"David Ripton","email":"dripton@redhat.com","username":"dripton"},"change_message_id":"71a10d50342d15834209903c9c448bb73b3c2c42","unresolved":false,"context_lines":[{"line_number":3136,"context_line":"    _scrub_empty_str_values(values, [\u0027volume_size\u0027])"},{"line_number":3137,"context_line":"    query \u003d _block_device_mapping_get_query(context).filter_by(id\u003dbdm_id)"},{"line_number":3138,"context_line":"    query.update(values)"},{"line_number":3139,"context_line":"    return query.first()"},{"line_number":3140,"context_line":""},{"line_number":3141,"context_line":""},{"line_number":3142,"context_line":"@require_context"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAPX%2F%2F2Mk%3D","line":3139,"updated":"2013-06-07 17:24:01.000000000","message":"\"update\" to me sounds like a void method.  Why is it returning a value now?","commit_id":"c0237c9fb1439ead034e923582e7bf39776ef6d3"},{"author":{"_account_id":1030,"name":"Chris Behrens","email":"cbehrens@codestud.com","username":"cbehrens"},"change_message_id":"df1cad1301be69003c18db7afea24296bef0a7d8","unresolved":false,"context_lines":[{"line_number":3136,"context_line":"    _scrub_empty_str_values(values, [\u0027volume_size\u0027])"},{"line_number":3137,"context_line":"    query \u003d _block_device_mapping_get_query(context).filter_by(id\u003dbdm_id)"},{"line_number":3138,"context_line":"    query.update(values)"},{"line_number":3139,"context_line":"    return query.first()"},{"line_number":3140,"context_line":""},{"line_number":3141,"context_line":""},{"line_number":3142,"context_line":"@require_context"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAPX%2F%2Fl9w%3D","line":3139,"in_reply_to":"AAAAPX%2F%2F2Mk%3D","updated":"2013-06-14 19:26:25.000000000","message":"I need the new model to pass it to cells.  And really it\u0027s also for consistency.  Almost all of our other DB API update methods return the changed model.  Take a look at instance_update for example.","commit_id":"c0237c9fb1439ead034e923582e7bf39776ef6d3"}],"nova/tests/cells/test_cells_messaging.py":[{"author":{"_account_id":5652,"name":"David Ripton","email":"dripton@redhat.com","username":"dripton"},"change_message_id":"71a10d50342d15834209903c9c448bb73b3c2c42","unresolved":false,"context_lines":[{"line_number":1426,"context_line":""},{"line_number":1427,"context_line":"        self.src_msg_runner.consoleauth_delete_tokens(self.ctxt, fake_uuid)"},{"line_number":1428,"context_line":""},{"line_number":1429,"context_line":"    def test_bdm_update_or_create_with_none_create(self):"},{"line_number":1430,"context_line":"        fake_bdm \u003d {\u0027id\u0027: \u0027fake_id\u0027,"},{"line_number":1431,"context_line":"                    \u0027volume_id\u0027: \u0027fake_volume_id\u0027}"},{"line_number":1432,"context_line":"        expected_bdm \u003d fake_bdm.copy()"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAPX%2F%2F2Mo%3D","line":1429,"updated":"2013-06-07 17:24:01.000000000","message":"There is a ton of duplication in this group of tests.  Do you think it\u0027s worth extracting a helper method so there\u0027s less code to read / change?","commit_id":"c0237c9fb1439ead034e923582e7bf39776ef6d3"},{"author":{"_account_id":1030,"name":"Chris Behrens","email":"cbehrens@codestud.com","username":"cbehrens"},"change_message_id":"df1cad1301be69003c18db7afea24296bef0a7d8","unresolved":false,"context_lines":[{"line_number":1426,"context_line":""},{"line_number":1427,"context_line":"        self.src_msg_runner.consoleauth_delete_tokens(self.ctxt, fake_uuid)"},{"line_number":1428,"context_line":""},{"line_number":1429,"context_line":"    def test_bdm_update_or_create_with_none_create(self):"},{"line_number":1430,"context_line":"        fake_bdm \u003d {\u0027id\u0027: \u0027fake_id\u0027,"},{"line_number":1431,"context_line":"                    \u0027volume_id\u0027: \u0027fake_volume_id\u0027}"},{"line_number":1432,"context_line":"        expected_bdm \u003d fake_bdm.copy()"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAPX%2F%2Fl9Q%3D","line":1429,"in_reply_to":"AAAAPX%2F%2F2Mo%3D","updated":"2013-06-14 19:26:25.000000000","message":"I don\u0027t think there\u0027s going to be a ton of shared code in the end.  The fake_bdm is the same in 2 tests.  And there\u0027s some mocks that are the same in 2 tests.   Other than that, pretty much everything is different in some way.. and needs to be.\n\nI could move the ReplayAll() and the call to msg_runner to a helper... that\u0027d eliminate 1 line or so per test. :)\n\nSo, no, I tend to not think it\u0027s really worth it...","commit_id":"c0237c9fb1439ead034e923582e7bf39776ef6d3"}]}
