)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":8247,"name":"Thang Pham","email":"thang.g.pham@gmail.com","username":"thang.pham"},"change_message_id":"6396f1d71f734db522fddbd44f92d2a264be042d","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Network: manage neutron client better in allocate_for_instance"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"A neutron client only needs to be created twice in the aforementioned"},{"line_number":10,"context_line":"mthod. The first time is for the tenant and the second, if necessary,"},{"line_number":11,"context_line":"is for the admin. This is in the event that a port binding extension"},{"line_number":12,"context_line":"is supported (only an adnmin user can read this)."},{"line_number":13,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"baa201ad_4f25b45a","line":10,"updated":"2014-10-06 01:29:03.000000000","message":"s/mthod/method/","commit_id":"49a34a06549acad232a8f32e1959cc026bd721df"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"eb3c2b2ad22485408499cf63d913f6329cbcc4b1","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Network: manage neutron client better in allocate_for_instance"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"A neutron client only needs to be created twice in the aforementioned"},{"line_number":10,"context_line":"mthod. The first time is for the tenant and the second, if necessary,"},{"line_number":11,"context_line":"is for the admin. This is in the event that a port binding extension"},{"line_number":12,"context_line":"is supported (only an adnmin user can read this)."},{"line_number":13,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"baa201ad_f2e2cb2d","line":10,"in_reply_to":"baa201ad_4f25b45a","updated":"2014-10-06 06:10:39.000000000","message":"Done","commit_id":"49a34a06549acad232a8f32e1959cc026bd721df"},{"author":{"_account_id":8247,"name":"Thang Pham","email":"thang.g.pham@gmail.com","username":"thang.pham"},"change_message_id":"6396f1d71f734db522fddbd44f92d2a264be042d","unresolved":false,"context_lines":[{"line_number":9,"context_line":"A neutron client only needs to be created twice in the aforementioned"},{"line_number":10,"context_line":"mthod. The first time is for the tenant and the second, if necessary,"},{"line_number":11,"context_line":"is for the admin. This is in the event that a port binding extension"},{"line_number":12,"context_line":"is supported (only an adnmin user can read this)."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"In addition to this is a client exists then the method will make use"},{"line_number":15,"context_line":"of it passing it to all internal methods called. This will enable them"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"baa201ad_8f223c50","line":12,"updated":"2014-10-06 01:29:03.000000000","message":"s/adnmin/admin/","commit_id":"49a34a06549acad232a8f32e1959cc026bd721df"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"eb3c2b2ad22485408499cf63d913f6329cbcc4b1","unresolved":false,"context_lines":[{"line_number":9,"context_line":"A neutron client only needs to be created twice in the aforementioned"},{"line_number":10,"context_line":"mthod. The first time is for the tenant and the second, if necessary,"},{"line_number":11,"context_line":"is for the admin. This is in the event that a port binding extension"},{"line_number":12,"context_line":"is supported (only an adnmin user can read this)."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"In addition to this is a client exists then the method will make use"},{"line_number":15,"context_line":"of it passing it to all internal methods called. This will enable them"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"baa201ad_12d3cf60","line":12,"in_reply_to":"baa201ad_8f223c50","updated":"2014-10-06 06:10:39.000000000","message":"Done","commit_id":"49a34a06549acad232a8f32e1959cc026bd721df"}],"nova/network/neutronv2/api.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6193b83e485f200472e4c542c5ad181b9dedc42b","unresolved":false,"context_lines":[{"line_number":277,"context_line":"            available_macs \u003d set(hypervisor_macs)"},{"line_number":278,"context_line":"        neutron \u003d neutronv2.get_client(context)"},{"line_number":279,"context_line":""},{"line_number":280,"context_line":"        # Requires admin creds to set port bindings"},{"line_number":281,"context_line":"        port_client \u003d (neutron if not"},{"line_number":282,"context_line":"                       self._has_port_binding_extension(context,"},{"line_number":283,"context_line":"                           neutron\u003dneutron) else"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_8ebb970d","line":280,"updated":"2014-10-20 16:16:38.000000000","message":"Note to self, we pull this up so it\u0027s outside the for loop where it\u0027s used.","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"3e777e8f79bc93ab8e4d59a52345d58b1090d248","unresolved":false,"context_lines":[{"line_number":277,"context_line":"            available_macs \u003d set(hypervisor_macs)"},{"line_number":278,"context_line":"        neutron \u003d neutronv2.get_client(context)"},{"line_number":279,"context_line":""},{"line_number":280,"context_line":"        # Requires admin creds to set port bindings"},{"line_number":281,"context_line":"        port_client \u003d (neutron if not"},{"line_number":282,"context_line":"                       self._has_port_binding_extension(context,"},{"line_number":283,"context_line":"                           neutron\u003dneutron) else"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_a6e78d3f","line":280,"in_reply_to":"9aa7fdbe_8ebb970d","updated":"2014-10-21 10:34:49.000000000","message":"Not sure that I understand the comment here but I have added a comment above explaining","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1448d3611243a088042c1b4221e55d5fecd1fde6","unresolved":false,"context_lines":[{"line_number":277,"context_line":"            available_macs \u003d set(hypervisor_macs)"},{"line_number":278,"context_line":"        neutron \u003d neutronv2.get_client(context)"},{"line_number":279,"context_line":""},{"line_number":280,"context_line":"        # Requires admin creds to set port bindings"},{"line_number":281,"context_line":"        port_client \u003d (neutron if not"},{"line_number":282,"context_line":"                       self._has_port_binding_extension(context,"},{"line_number":283,"context_line":"                           neutron\u003dneutron) else"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_58ca036f","line":280,"in_reply_to":"9aa7fdbe_a6e78d3f","updated":"2014-10-22 19:02:19.000000000","message":"I was just making a note to myself in the review that this is why this was pulled up, not necessarily that it needs a comment in the code.","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6193b83e485f200472e4c542c5ad181b9dedc42b","unresolved":false,"context_lines":[{"line_number":436,"context_line":"                            if self._has_port_binding_extension(context,"},{"line_number":437,"context_line":"                                neutron\u003dneutron):"},{"line_number":438,"context_line":"                                port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d None"},{"line_number":439,"context_line":"                                port_client \u003d neutronv2.get_client("},{"line_number":440,"context_line":"                                    context, admin\u003dTrue)"},{"line_number":441,"context_line":"                            else:"},{"line_number":442,"context_line":"                                port_client \u003d neutron"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_6e5593c5","line":439,"updated":"2014-10-20 16:16:38.000000000","message":"Looks like you missed this one.","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"3e777e8f79bc93ab8e4d59a52345d58b1090d248","unresolved":false,"context_lines":[{"line_number":436,"context_line":"                            if self._has_port_binding_extension(context,"},{"line_number":437,"context_line":"                                neutron\u003dneutron):"},{"line_number":438,"context_line":"                                port_req_body[\u0027port\u0027][\u0027binding:host_id\u0027] \u003d None"},{"line_number":439,"context_line":"                                port_client \u003d neutronv2.get_client("},{"line_number":440,"context_line":"                                    context, admin\u003dTrue)"},{"line_number":441,"context_line":"                            else:"},{"line_number":442,"context_line":"                                port_client \u003d neutron"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_c61731ec","line":439,"in_reply_to":"9aa7fdbe_6e5593c5","updated":"2014-10-21 10:34:49.000000000","message":"Done","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6193b83e485f200472e4c542c5ad181b9dedc42b","unresolved":false,"context_lines":[{"line_number":439,"context_line":"                                port_client \u003d neutronv2.get_client("},{"line_number":440,"context_line":"                                    context, admin\u003dTrue)"},{"line_number":441,"context_line":"                            else:"},{"line_number":442,"context_line":"                                port_client \u003d neutron"},{"line_number":443,"context_line":"                            port_client.update_port(port_id, port_req_body)"},{"line_number":444,"context_line":"                        except Exception:"},{"line_number":445,"context_line":"                            msg \u003d _LE(\"Failed to update port %s\")"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_ae5e9be7","line":442,"updated":"2014-10-20 16:16:38.000000000","message":"ditto","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"3e777e8f79bc93ab8e4d59a52345d58b1090d248","unresolved":false,"context_lines":[{"line_number":439,"context_line":"                                port_client \u003d neutronv2.get_client("},{"line_number":440,"context_line":"                                    context, admin\u003dTrue)"},{"line_number":441,"context_line":"                            else:"},{"line_number":442,"context_line":"                                port_client \u003d neutron"},{"line_number":443,"context_line":"                            port_client.update_port(port_id, port_req_body)"},{"line_number":444,"context_line":"                        except Exception:"},{"line_number":445,"context_line":"                            msg \u003d _LE(\"Failed to update port %s\")"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_86e4490e","line":442,"in_reply_to":"9aa7fdbe_ae5e9be7","updated":"2014-10-21 10:34:49.000000000","message":"Done","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6193b83e485f200472e4c542c5ad181b9dedc42b","unresolved":false,"context_lines":[{"line_number":447,"context_line":""},{"line_number":448,"context_line":"                    self._delete_ports(neutron, instance, created_port_ids)"},{"line_number":449,"context_line":""},{"line_number":450,"context_line":"        nw_info \u003d self.get_instance_nw_info(context, instance,"},{"line_number":451,"context_line":"                                            networks\u003dnets_in_requested_order,"},{"line_number":452,"context_line":"                                            port_ids\u003dports_in_requested_order)"},{"line_number":453,"context_line":"        # NOTE(danms): Only return info about ports we created in this run."}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_4ef52f82","line":450,"updated":"2014-10-20 16:16:38.000000000","message":"This eventually calls through to _build_network_info_model which gets the admin client.","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"3e777e8f79bc93ab8e4d59a52345d58b1090d248","unresolved":false,"context_lines":[{"line_number":447,"context_line":""},{"line_number":448,"context_line":"                    self._delete_ports(neutron, instance, created_port_ids)"},{"line_number":449,"context_line":""},{"line_number":450,"context_line":"        nw_info \u003d self.get_instance_nw_info(context, instance,"},{"line_number":451,"context_line":"                                            networks\u003dnets_in_requested_order,"},{"line_number":452,"context_line":"                                            port_ids\u003dports_in_requested_order)"},{"line_number":453,"context_line":"        # NOTE(danms): Only return info about ports we created in this run."}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_1fac18a0","line":450,"in_reply_to":"9aa7fdbe_4ef52f82","updated":"2014-10-21 10:34:49.000000000","message":"good catch. this one was really buried deep.","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6193b83e485f200472e4c542c5ad181b9dedc42b","unresolved":false,"context_lines":[{"line_number":1356,"context_line":"        \"\"\""},{"line_number":1357,"context_line":""},{"line_number":1358,"context_line":"        search_opts \u003d {\u0027tenant_id\u0027: instance[\u0027project_id\u0027],"},{"line_number":1359,"context_line":"                       \u0027device_id\u0027: instance[\u0027uuid\u0027], }"},{"line_number":1360,"context_line":"        client \u003d neutronv2.get_client(context, admin\u003dTrue)"},{"line_number":1361,"context_line":"        data \u003d client.list_ports(**search_opts)"},{"line_number":1362,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_eefee36a","line":1359,"updated":"2014-10-20 16:16:38.000000000","message":"Missed this one, and it\u0027s quite nested.","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"3e777e8f79bc93ab8e4d59a52345d58b1090d248","unresolved":false,"context_lines":[{"line_number":1356,"context_line":"        \"\"\""},{"line_number":1357,"context_line":""},{"line_number":1358,"context_line":"        search_opts \u003d {\u0027tenant_id\u0027: instance[\u0027project_id\u0027],"},{"line_number":1359,"context_line":"                       \u0027device_id\u0027: instance[\u0027uuid\u0027], }"},{"line_number":1360,"context_line":"        client \u003d neutronv2.get_client(context, admin\u003dTrue)"},{"line_number":1361,"context_line":"        data \u003d client.list_ports(**search_opts)"},{"line_number":1362,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_bfc14c30","line":1359,"in_reply_to":"9aa7fdbe_eefee36a","updated":"2014-10-21 10:34:49.000000000","message":"Done","commit_id":"e9d8c8bf8edb279ff22996321873079c12cda5d9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e6163dbdabd885b8a75b1ffae54ffc91a2d1d8fe","unresolved":false,"context_lines":[{"line_number":1367,"context_line":""},{"line_number":1368,"context_line":"        search_opts \u003d {\u0027tenant_id\u0027: instance[\u0027project_id\u0027],"},{"line_number":1369,"context_line":"                       \u0027device_id\u0027: instance[\u0027uuid\u0027], }"},{"line_number":1370,"context_line":"        if not admin_client:"},{"line_number":1371,"context_line":"            client \u003d neutronv2.get_client(context, admin\u003dTrue)"},{"line_number":1372,"context_line":"        else:"},{"line_number":1373,"context_line":"            client \u003d admin_client"}],"source_content_type":"text/x-python","patch_set":4,"id":"9aa7fdbe_c158808c","line":1370,"updated":"2014-10-24 21:07:15.000000000","message":"nit: could be more specific:\n\nif admin_client is None:","commit_id":"01d1fa3d07b52de1d38b4211ab3cc02b30d8613a"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"3186eb27cd080a425470ab454c636b2e72c5544e","unresolved":false,"context_lines":[{"line_number":1367,"context_line":""},{"line_number":1368,"context_line":"        search_opts \u003d {\u0027tenant_id\u0027: instance[\u0027project_id\u0027],"},{"line_number":1369,"context_line":"                       \u0027device_id\u0027: instance[\u0027uuid\u0027], }"},{"line_number":1370,"context_line":"        if not admin_client:"},{"line_number":1371,"context_line":"            client \u003d neutronv2.get_client(context, admin\u003dTrue)"},{"line_number":1372,"context_line":"        else:"},{"line_number":1373,"context_line":"            client \u003d admin_client"}],"source_content_type":"text/x-python","patch_set":4,"id":"9aa7fdbe_a51e1f5d","line":1370,"in_reply_to":"9aa7fdbe_c158808c","updated":"2014-10-26 05:47:35.000000000","message":"Done","commit_id":"01d1fa3d07b52de1d38b4211ab3cc02b30d8613a"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e6163dbdabd885b8a75b1ffae54ffc91a2d1d8fe","unresolved":false,"context_lines":[{"line_number":1370,"context_line":"        if not admin_client:"},{"line_number":1371,"context_line":"            client \u003d neutronv2.get_client(context, admin\u003dTrue)"},{"line_number":1372,"context_line":"        else:"},{"line_number":1373,"context_line":"            client \u003d admin_client"},{"line_number":1374,"context_line":""},{"line_number":1375,"context_line":"        data \u003d client.list_ports(**search_opts)"},{"line_number":1376,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"9aa7fdbe_e1d4a4be","line":1373,"updated":"2014-10-24 21:07:15.000000000","message":"I wonder if we should check that the context in this case is an admin, or could someone be passing us an admin context and not an admin client, and vice-versa, by mistake?  Maybe I\u0027m over-thinking this.\n\nI guess the context doesn\u0027t need to be an admin context to get an admin client, you can just pass admin\u003dTrue:\n\nhttp://git.openstack.org/cgit/openstack/nova/tree/nova/network/neutronv2/__init__.py#n97\n\nSo I guess it\u0027s an unfounded concern - I just get the feeling there is a bug waiting to happen at some point.","commit_id":"01d1fa3d07b52de1d38b4211ab3cc02b30d8613a"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"3186eb27cd080a425470ab454c636b2e72c5544e","unresolved":false,"context_lines":[{"line_number":1370,"context_line":"        if not admin_client:"},{"line_number":1371,"context_line":"            client \u003d neutronv2.get_client(context, admin\u003dTrue)"},{"line_number":1372,"context_line":"        else:"},{"line_number":1373,"context_line":"            client \u003d admin_client"},{"line_number":1374,"context_line":""},{"line_number":1375,"context_line":"        data \u003d client.list_ports(**search_opts)"},{"line_number":1376,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"9aa7fdbe_c52323a5","line":1373,"in_reply_to":"9aa7fdbe_e1d4a4be","updated":"2014-10-26 05:47:35.000000000","message":"I will think about it. It is certainly something that we can do in a subsequent patch.","commit_id":"01d1fa3d07b52de1d38b4211ab3cc02b30d8613a"}]}
