)]}'
{"doc/source/devref/address_scopes.rst":[{"author":{"_account_id":1131,"name":"Brian Haley","email":"haleyb.dev@gmail.com","username":"brian-haley"},"change_message_id":"b796626e20b6ba19142f74483a54e9138d467158","unresolved":false,"context_lines":[{"line_number":100,"context_line":""},{"line_number":101,"context_line":"The reference implementation honors address scopes.  Within an address scope,"},{"line_number":102,"context_line":"addresses route freely (barring any FW rules or other external restrictions)."},{"line_number":103,"context_line":"Between scopes, routed is prevented unless address translation is used.  For now, floating IPs are the only place"},{"line_number":104,"context_line":"where traffic crosses scope boundaries.  The 1-1 NAT allows this to happen."},{"line_number":105,"context_line":""},{"line_number":106,"context_line":".. TODO (Carl) Implement NAT for floating ips crossing scopes"}],"source_content_type":"text/x-rst","patch_set":22,"id":"9a8ffd7b_858ed225","line":103,"updated":"2015-12-01 03:21:14.000000000","message":"The formatting of this line seems strange, at least in both firefox and chromium.\n\nAnd just a nit, but it would be good to stay with either IPs or ips throughout.","commit_id":"15d6f433aef1658942b6763ddb63405def900ca9"}],"neutron/agent/l3/agent.py":[{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"d07268920557b90fc25300114361d21b82391494","unresolved":false,"context_lines":[{"line_number":82,"context_line":"        1.6 - Added process_prefix_update"},{"line_number":83,"context_line":"        1.7 - DVR support: new L3 plugin methods added."},{"line_number":84,"context_line":"        1.8 - Added address scope information"},{"line_number":85,"context_line":"              - delete_agent_gateway_port"},{"line_number":86,"context_line":"    \"\"\""},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"    def __init__(self, topic, host):"}],"source_content_type":"text/x-python","patch_set":28,"id":"1a7b0d38_29aedd2e","line":85,"updated":"2015-12-23 10:14:41.000000000","message":"I guess \"- delete_agent_gateway_port\" should be with 1.7","commit_id":"6444d799bfbc5da22ee900db6445a726cacaab13"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"448acbb8ec40addba4d1c1520e8793fefa2dbaa2","unresolved":false,"context_lines":[{"line_number":82,"context_line":"        1.6 - Added process_prefix_update"},{"line_number":83,"context_line":"        1.7 - DVR support: new L3 plugin methods added."},{"line_number":84,"context_line":"        1.8 - Added address scope information"},{"line_number":85,"context_line":"              - delete_agent_gateway_port"},{"line_number":86,"context_line":"    \"\"\""},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"    def __init__(self, topic, host):"}],"source_content_type":"text/x-python","patch_set":28,"id":"1a7b0d38_0a042015","line":85,"in_reply_to":"1a7b0d38_29aedd2e","updated":"2015-12-23 17:17:02.000000000","message":"Oops!","commit_id":"6444d799bfbc5da22ee900db6445a726cacaab13"}],"neutron/api/rpc/handlers/l3_rpc.py":[{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"204b2241ae6840eaa9319d62868d79d96da70891","unresolved":false,"context_lines":[{"line_number":43,"context_line":"    # 1.4 Added L3 HA update_router_state. This method was later removed,"},{"line_number":44,"context_line":"    #     since it was unused. The RPC version was not changed"},{"line_number":45,"context_line":"    # 1.5 Added update_ha_routers_states"},{"line_number":46,"context_line":"    # 1.6 Added address scopes"},{"line_number":47,"context_line":"    target \u003d oslo_messaging.Target(version\u003d\u00271.6\u0027)"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":3,"id":"3afb71cf_e23283a6","line":46,"updated":"2015-06-09 20:54:14.000000000","message":"I\u0027m not sure that I want to add a new version.  This patch only adds new attributes that are ignored if the agent doesn\u0027t understand them.  If the agent wants them, it can still ignore them if they\u0027re not present.  So, we have backwards compatibility in both directions.  Thoughts?","commit_id":"b07ff9c2930007bc930c83e03de0cb3edbf5db9b"}],"neutron/db/l3_db.py":[{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"787379773ceb3d9753b459d084caac9dfbd53b6e","unresolved":false,"context_lines":[{"line_number":1136,"context_line":"        if not router_ids:"},{"line_number":1137,"context_line":"            return []"},{"line_number":1138,"context_line":""},{"line_number":1139,"context_line":"        filters \u003d {\u0027router_id\u0027: router_ids}"},{"line_number":1140,"context_line":""},{"line_number":1141,"context_line":"        query \u003d context.session.query(FloatingIP, models_v2.SubnetPool.id)"},{"line_number":1142,"context_line":"        query \u003d query.join(models_v2.Port,"}],"source_content_type":"text/x-python","patch_set":1,"id":"3afb71cf_d1c9c879","line":1139,"updated":"2015-06-08 23:14:52.000000000","message":"Remove this line.","commit_id":"541968484cc987b8ccf40f9a6e20294d108579a5"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"787379773ceb3d9753b459d084caac9dfbd53b6e","unresolved":false,"context_lines":[{"line_number":1142,"context_line":"        query \u003d query.join(models_v2.Port,"},{"line_number":1143,"context_line":"            FloatingIP.fixed_port_id \u003d\u003d models_v2.Port.id)"},{"line_number":1144,"context_line":"        # TODO This can produce more than one row but the resulting pool_id"},{"line_number":1145,"context_line":"        # should always be the same."},{"line_number":1146,"context_line":"        query \u003d query.outerjoin(models_v2.Subnet,"},{"line_number":1147,"context_line":"            models_v2.Subnet.network_id \u003d\u003d models_v2.Port.network_id)"},{"line_number":1148,"context_line":"        query \u003d query.outerjoin(models_v2.SubnetPool,"}],"source_content_type":"text/x-python","patch_set":1,"id":"3afb71cf_31b81ce5","line":1145,"updated":"2015-06-08 23:14:52.000000000","message":"This needs more work.  Essentially, this outerjoin below can produce more than one row since there can be more than one subnet on a network.\n\nCome to think of it.  I need to also include only v4 subnets since there may be v6 subnets on the same network with a different scope.","commit_id":"541968484cc987b8ccf40f9a6e20294d108579a5"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"787379773ceb3d9753b459d084caac9dfbd53b6e","unresolved":false,"context_lines":[{"line_number":1150,"context_line":""},{"line_number":1151,"context_line":"        # TODO(Carl) When AddressScope is a first-class object, outerjoin it"},{"line_number":1152,"context_line":""},{"line_number":1153,"context_line":"        # Filter out on router_ids"},{"line_number":1154,"context_line":"        query \u003d query.filter(FloatingIP.router_id.in_(router_ids))"},{"line_number":1155,"context_line":""},{"line_number":1156,"context_line":"        def make_floatingip_dict_with_scope(row):"}],"source_content_type":"text/x-python","patch_set":1,"id":"3afb71cf_d11b081a","line":1153,"updated":"2015-06-08 23:14:52.000000000","message":"Redundant comment.  I meant to remove it.","commit_id":"541968484cc987b8ccf40f9a6e20294d108579a5"},{"author":{"_account_id":14258,"name":"Ryan Tidwell","email":"rktidwell85@gmail.com","username":"tidwellr"},"change_message_id":"13ece2e7a66965fb939c95a7bc2d226f9c2ef3af","unresolved":false,"context_lines":[{"line_number":1137,"context_line":"        if not router_ids:"},{"line_number":1138,"context_line":"            return []"},{"line_number":1139,"context_line":""},{"line_number":1140,"context_line":"        query \u003d context.session.query(FloatingIP, models_v2.SubnetPool.id)"},{"line_number":1141,"context_line":"        query \u003d query.join(models_v2.Port,"},{"line_number":1142,"context_line":"            FloatingIP.fixed_port_id \u003d\u003d models_v2.Port.id)"},{"line_number":1143,"context_line":"        # Outer join of Subnet can cause each ip to have more than one row."}],"source_content_type":"text/x-python","patch_set":7,"id":"ba3cc151_961c9f14","line":1140,"updated":"2015-06-30 19:31:21.000000000","message":"It would interesting to see what the SQL generated by this block of code looks like.  Under the hood sqlalchemy may be following the backrefs on FloatingIP and joining extraneous tables.  This just bit me recently on some unrelated things, I was a little surprised by the actual query generated by sqlalchemy.","commit_id":"e99b6ea8a18ae47b075e5bf069ce6c88179bda79"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"18f0a3313ae22da883246d2e9b4fe900b12cbe49","unresolved":false,"context_lines":[{"line_number":1202,"context_line":""},{"line_number":1203,"context_line":"            # Just hit the first row of each group"},{"line_number":1204,"context_line":"            for key, value in group_iterator:"},{"line_number":1205,"context_line":"                yield value.next()"},{"line_number":1206,"context_line":""},{"line_number":1207,"context_line":"        def make_floatingip_dict_with_scope(row):"},{"line_number":1208,"context_line":"            floatingip_db, address_scope_id \u003d row"}],"source_content_type":"text/x-python","patch_set":13,"id":"7a2fa921_7e5cba18","line":1205,"updated":"2015-10-09 22:57:56.000000000","message":"Calling .next() here is why python3 fails.","commit_id":"af7c238da9ffe29a229c6d6e85dee6b978415604"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"23fe0418e6e8f9e49fe5d1aa0ef07ac4b564345f","unresolved":false,"context_lines":[{"line_number":1211,"context_line":"        query \u003d query.filter(FloatingIP.router_id.in_(router_ids))"},{"line_number":1212,"context_line":""},{"line_number":1213,"context_line":"        return [self._make_floatingip_dict_with_scope(*row)"},{"line_number":1214,"context_line":"                for row in self._unique_floatingip_iterator(self)]"},{"line_number":1215,"context_line":""},{"line_number":1216,"context_line":"    def _get_sync_interfaces(self, context, router_ids, device_owners\u003dNone):"},{"line_number":1217,"context_line":"        \"\"\"Query router interfaces that relate to list of router_ids.\"\"\""}],"source_content_type":"text/x-python","patch_set":16,"id":"3a29b11f_a330a1e9","line":1214,"updated":"2015-10-19 22:52:02.000000000","message":"This shouldn\u0027t be passing \"self\".  It needs to pass \"query\".  I messed it up last minute when I decided to change it to a staticmethod.  I removed the wrong argument!  Yikes!","commit_id":"e807029c0d78e5a99490aee25df34ac749ce441d"},{"author":{"_account_id":12912,"name":"John Belamaric","email":"jbelamaric@infoblox.com","username":"johnbelamaric"},"change_message_id":"32bb8eb57d0f15b9a6670873c7ac5d99a5a40019","unresolved":false,"context_lines":[{"line_number":1190,"context_line":"        address scope of the fixed IP.  The router needs to know this to"},{"line_number":1191,"context_line":"        distinguish it from other scopes."},{"line_number":1192,"context_line":""},{"line_number":1193,"context_line":"        There are a few redirections to go through to discover the address"},{"line_number":1194,"context_line":"        scope from the floating ip."},{"line_number":1195,"context_line":"        \"\"\""},{"line_number":1196,"context_line":"        if not router_ids:"}],"source_content_type":"text/x-python","patch_set":17,"id":"3a29b11f_a01393b7","line":1193,"updated":"2015-10-20 14:54:38.000000000","message":"nit: s/redirections/indirections/","commit_id":"67cc7bab564892e654e614ba77227b40a1f6069d"},{"author":{"_account_id":12912,"name":"John Belamaric","email":"jbelamaric@infoblox.com","username":"johnbelamaric"},"change_message_id":"32bb8eb57d0f15b9a6670873c7ac5d99a5a40019","unresolved":false,"context_lines":[{"line_number":1202,"context_line":"            FloatingIP.fixed_port_id \u003d\u003d models_v2.Port.id)"},{"line_number":1203,"context_line":"        # Outer join of Subnet can cause each ip to have more than one row."},{"line_number":1204,"context_line":"        query \u003d query.outerjoin(models_v2.Subnet,"},{"line_number":1205,"context_line":"            models_v2.Subnet.network_id \u003d\u003d models_v2.Port.network_id)"},{"line_number":1206,"context_line":"        query \u003d query.filter(models_v2.Subnet.ip_version \u003d\u003d 4)"},{"line_number":1207,"context_line":"        query \u003d query.outerjoin(models_v2.SubnetPool,"},{"line_number":1208,"context_line":"            models_v2.Subnet.subnetpool_id \u003d\u003d models_v2.SubnetPool.id)"}],"source_content_type":"text/x-python","patch_set":17,"id":"3a29b11f_80169753","line":1205,"updated":"2015-10-20 14:54:38.000000000","message":"So, I am assuming there must be a constraint preventing subnets from different address scopes from being on the same network (and therefore the same port)? That could be an issue if we want to allow VLAN tags on a port (vlan-aware-vms) and have those tags represent mappings to different address scopes (a la VRF-lite). This would seem to be a pretty common use case - that is, providing a single VM to have IP addresses in multiple address scopes on the same port.","commit_id":"67cc7bab564892e654e614ba77227b40a1f6069d"},{"author":{"_account_id":4187,"name":"Ryan Tidwell","email":"rtidwell@suse.com","username":"ryan-tidwell"},"change_message_id":"d1ec5413485589fb62d9ec70a3ed3ac40a1302a6","unresolved":false,"context_lines":[{"line_number":1202,"context_line":"            FloatingIP.fixed_port_id \u003d\u003d models_v2.Port.id)"},{"line_number":1203,"context_line":"        # Outer join of Subnet can cause each ip to have more than one row."},{"line_number":1204,"context_line":"        query \u003d query.outerjoin(models_v2.Subnet,"},{"line_number":1205,"context_line":"            models_v2.Subnet.network_id \u003d\u003d models_v2.Port.network_id)"},{"line_number":1206,"context_line":"        query \u003d query.filter(models_v2.Subnet.ip_version \u003d\u003d 4)"},{"line_number":1207,"context_line":"        query \u003d query.outerjoin(models_v2.SubnetPool,"},{"line_number":1208,"context_line":"            models_v2.Subnet.subnetpool_id \u003d\u003d models_v2.SubnetPool.id)"}],"source_content_type":"text/x-python","patch_set":17,"id":"fa80f949_f5ec3c91","line":1205,"in_reply_to":"3a29b11f_80169753","updated":"2015-11-03 18:15:39.000000000","message":"The way I understand the current proposal for VLAN-aware VM\u0027s is that the trunk port is modeled as a new entity that doesn\u0027t really belong to a network.  The subports are are modeled as proper Neutron ports that have affinity to specific networks.  Because the trunk port does not have affinity to a Neutron network or a subnet I don\u0027t think there\u0027s an issue.  If that model were to change there could potentially be an issue.  As currently designed I don\u0027t see any problems with this.","commit_id":"67cc7bab564892e654e614ba77227b40a1f6069d"},{"author":{"_account_id":4187,"name":"Ryan Tidwell","email":"rtidwell@suse.com","username":"ryan-tidwell"},"change_message_id":"44b0dbcd9bb896849321967093b724d1425af41d","unresolved":false,"context_lines":[{"line_number":1205,"context_line":"        query \u003d query.join(models_v2.Port,"},{"line_number":1206,"context_line":"            FloatingIP.fixed_port_id \u003d\u003d models_v2.Port.id)"},{"line_number":1207,"context_line":"        # Outer join of Subnet can cause each ip to have more than one row."},{"line_number":1208,"context_line":"        query \u003d query.outerjoin(models_v2.Subnet,"},{"line_number":1209,"context_line":"            models_v2.Subnet.network_id \u003d\u003d models_v2.Port.network_id)"},{"line_number":1210,"context_line":"        query \u003d query.filter(models_v2.Subnet.ip_version \u003d\u003d 4)"},{"line_number":1211,"context_line":"        query \u003d query.outerjoin(models_v2.SubnetPool,"}],"source_content_type":"text/x-python","patch_set":19,"id":"fa80f949_0712f362","line":1208,"updated":"2015-11-03 18:18:34.000000000","message":"Because Subnet has backrefs on SubnetRoute and DNSNameServer, you might be getting an unnecessary join across these tables when sqlalchemy renders the SQL.  You might explore disabling eager loading with enable_eagerloads(False).  As a disclaimer, I\u0027m just getting dangerous with sqlalchemy so this might not be the best way to remove if unnecessary joins (if sqlalchemy does in fact render the SQL the way I *think* it does)","commit_id":"36b94aef8fd8c07f84bf0898d6c49d396df9c653"},{"author":{"_account_id":4187,"name":"Ryan Tidwell","email":"rtidwell@suse.com","username":"ryan-tidwell"},"change_message_id":"e5cb18fafbb034eff81749de229c7d5c72c51e07","unresolved":false,"context_lines":[{"line_number":1205,"context_line":"        query \u003d query.join(models_v2.Port,"},{"line_number":1206,"context_line":"            FloatingIP.fixed_port_id \u003d\u003d models_v2.Port.id)"},{"line_number":1207,"context_line":"        # Outer join of Subnet can cause each ip to have more than one row."},{"line_number":1208,"context_line":"        query \u003d query.outerjoin(models_v2.Subnet,"},{"line_number":1209,"context_line":"            models_v2.Subnet.network_id \u003d\u003d models_v2.Port.network_id)"},{"line_number":1210,"context_line":"        query \u003d query.filter(models_v2.Subnet.ip_version \u003d\u003d 4)"},{"line_number":1211,"context_line":"        query \u003d query.outerjoin(models_v2.SubnetPool,"}],"source_content_type":"text/x-python","patch_set":19,"id":"fa80f949_aaa72e4e","line":1208,"in_reply_to":"fa80f949_0712f362","updated":"2015-11-03 18:36:01.000000000","message":"I got curious and went to see what this query renders.  It looks good, I\u0027ll be spending more time with sqlachemy, sometimes it renders unnecessary joins, but it doesn\u0027t in this case.","commit_id":"36b94aef8fd8c07f84bf0898d6c49d396df9c653"},{"author":{"_account_id":261,"name":"Salvatore Orlando","email":"salv.orlando@gmail.com","username":"salvatore-orlando"},"change_message_id":"fd55a3bf129ca0fa291b6c39ee769f5ad3bbeb92","unresolved":false,"context_lines":[{"line_number":1175,"context_line":"        # Group rows by fip id.  They must be sorted by same."},{"line_number":1176,"context_line":"        q \u003d query.order_by(FloatingIP.id)"},{"line_number":1177,"context_line":"        keyfunc \u003d lambda row: row[0][\u0027id\u0027]"},{"line_number":1178,"context_line":"        group_iterator \u003d itertools.groupby(q, keyfunc)"},{"line_number":1179,"context_line":""},{"line_number":1180,"context_line":"        # Just hit the first row of each group"},{"line_number":1181,"context_line":"        for key, value in group_iterator:"}],"source_content_type":"text/x-python","patch_set":20,"id":"ba8a016a_84721aac","line":1178,"updated":"2015-11-17 19:02:31.000000000","message":"while the case in which we would get multiple IPs is probably a user error after - how do you guarantee that the row returned here is really the one to which the floating ip\u0027s fixed_ip_address refers to?\n\nAlso, could you have used a query for doing the group_by operation?","commit_id":"1c9681bc77ef12453fa6fb239635a999732c240a"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"1f1d408c21a07db86c80faf5edaa7576d6dbbe73","unresolved":false,"context_lines":[{"line_number":1175,"context_line":"        # Group rows by fip id.  They must be sorted by same."},{"line_number":1176,"context_line":"        q \u003d query.order_by(FloatingIP.id)"},{"line_number":1177,"context_line":"        keyfunc \u003d lambda row: row[0][\u0027id\u0027]"},{"line_number":1178,"context_line":"        group_iterator \u003d itertools.groupby(q, keyfunc)"},{"line_number":1179,"context_line":""},{"line_number":1180,"context_line":"        # Just hit the first row of each group"},{"line_number":1181,"context_line":"        for key, value in group_iterator:"}],"source_content_type":"text/x-python","patch_set":20,"id":"9a8ffd7b_d84d5d9a","line":1178,"in_reply_to":"9a8ffd7b_b8bc196d","updated":"2015-12-02 00:07:18.000000000","message":"You know.  I might be able to do this by joining through IPAllocation which would avoid the multiplicity of Subnet but would add one more table indirection.\n\nWhat do you think?","commit_id":"1c9681bc77ef12453fa6fb239635a999732c240a"},{"author":{"_account_id":261,"name":"Salvatore Orlando","email":"salv.orlando@gmail.com","username":"salvatore-orlando"},"change_message_id":"2d94c83b1271b573327169fda7106e20aafef154","unresolved":false,"context_lines":[{"line_number":1175,"context_line":"        # Group rows by fip id.  They must be sorted by same."},{"line_number":1176,"context_line":"        q \u003d query.order_by(FloatingIP.id)"},{"line_number":1177,"context_line":"        keyfunc \u003d lambda row: row[0][\u0027id\u0027]"},{"line_number":1178,"context_line":"        group_iterator \u003d itertools.groupby(q, keyfunc)"},{"line_number":1179,"context_line":""},{"line_number":1180,"context_line":"        # Just hit the first row of each group"},{"line_number":1181,"context_line":"        for key, value in group_iterator:"}],"source_content_type":"text/x-python","patch_set":20,"id":"9a8ffd7b_2071730c","line":1178,"in_reply_to":"9a8ffd7b_d84d5d9a","updated":"2015-12-03 11:44:07.000000000","message":"As you will have \"multiple rows with the same fixed IP but going through different subnets\" then you should be fine always fetching the first row for each group as you did. Paying the price for another join is not worth, especially since this condition when you\u0027d get multiple rows does not really seem very common.","commit_id":"1c9681bc77ef12453fa6fb239635a999732c240a"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"4de2a4b5543e28a633d266ac6aab5a92e48e4d11","unresolved":false,"context_lines":[{"line_number":1175,"context_line":"        # Group rows by fip id.  They must be sorted by same."},{"line_number":1176,"context_line":"        q \u003d query.order_by(FloatingIP.id)"},{"line_number":1177,"context_line":"        keyfunc \u003d lambda row: row[0][\u0027id\u0027]"},{"line_number":1178,"context_line":"        group_iterator \u003d itertools.groupby(q, keyfunc)"},{"line_number":1179,"context_line":""},{"line_number":1180,"context_line":"        # Just hit the first row of each group"},{"line_number":1181,"context_line":"        for key, value in group_iterator:"}],"source_content_type":"text/x-python","patch_set":20,"id":"9a8ffd7b_b8bc196d","line":1178,"in_reply_to":"ba8a016a_84721aac","updated":"2015-12-02 00:05:28.000000000","message":"The comment on L1206 was my attempt at explaining why this happens.  But, it is terse and not quite attached to this context so I can see why it didn\u0027t help.\n\nIt isn\u0027t that we get multiple IPs and it isn\u0027t user error.  The problem arises when the query looks through the Subnet to get the address scope id from the SubnetPool.\n\n  FloatingIP\n    -\u003e Port\n    -\u003e Subnet (Might be more than one of these with the same network_id)\n    -\u003e SubnetPool\n\nAn outer join is used because of the multiplicity of Subnets that could be found.  This can end up with multiple rows in the result with the same fixed IP address but going through different Subnets.\n\nYou might think that you can get different answers in the different rows here.  But, we already have a constraint that all of the Subnets on a Network must come from the same address scope (or no address scope).\n\nI couldn\u0027t figure out a way to do this in the query.  Otherwise, I would\u0027ve done it.  Do you know of a way?","commit_id":"1c9681bc77ef12453fa6fb239635a999732c240a"},{"author":{"_account_id":261,"name":"Salvatore Orlando","email":"salv.orlando@gmail.com","username":"salvatore-orlando"},"change_message_id":"fd55a3bf129ca0fa291b6c39ee769f5ad3bbeb92","unresolved":false,"context_lines":[{"line_number":1206,"context_line":"        # Outer join of Subnet can cause each ip to have more than one row."},{"line_number":1207,"context_line":"        query \u003d query.outerjoin(models_v2.Subnet,"},{"line_number":1208,"context_line":"            models_v2.Subnet.network_id \u003d\u003d models_v2.Port.network_id)"},{"line_number":1209,"context_line":"        query \u003d query.filter(models_v2.Subnet.ip_version \u003d\u003d 4)"},{"line_number":1210,"context_line":"        query \u003d query.outerjoin(models_v2.SubnetPool,"},{"line_number":1211,"context_line":"            models_v2.Subnet.subnetpool_id \u003d\u003d models_v2.SubnetPool.id)"},{"line_number":1212,"context_line":""}],"source_content_type":"text/x-python","patch_set":20,"id":"ba8a016a_869f814f","line":1209,"updated":"2015-11-17 19:02:31.000000000","message":"expect someone in the future to raise a bug because v6 floating IPs don\u0027t work ;)","commit_id":"1c9681bc77ef12453fa6fb239635a999732c240a"},{"author":{"_account_id":261,"name":"Salvatore Orlando","email":"salv.orlando@gmail.com","username":"salvatore-orlando"},"change_message_id":"2d94c83b1271b573327169fda7106e20aafef154","unresolved":false,"context_lines":[{"line_number":1206,"context_line":"        # Outer join of Subnet can cause each ip to have more than one row."},{"line_number":1207,"context_line":"        query \u003d query.outerjoin(models_v2.Subnet,"},{"line_number":1208,"context_line":"            models_v2.Subnet.network_id \u003d\u003d models_v2.Port.network_id)"},{"line_number":1209,"context_line":"        query \u003d query.filter(models_v2.Subnet.ip_version \u003d\u003d 4)"},{"line_number":1210,"context_line":"        query \u003d query.outerjoin(models_v2.SubnetPool,"},{"line_number":1211,"context_line":"            models_v2.Subnet.subnetpool_id \u003d\u003d models_v2.SubnetPool.id)"},{"line_number":1212,"context_line":""}],"source_content_type":"text/x-python","patch_set":20,"id":"9a8ffd7b_436b61b7","line":1209,"in_reply_to":"9a8ffd7b_38dee96d","updated":"2015-12-03 11:44:07.000000000","message":"It does not change anything indeed... but now it\u0027s your fault if people won\u0027t be able to do v6 NAT.","commit_id":"1c9681bc77ef12453fa6fb239635a999732c240a"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"4de2a4b5543e28a633d266ac6aab5a92e48e4d11","unresolved":false,"context_lines":[{"line_number":1206,"context_line":"        # Outer join of Subnet can cause each ip to have more than one row."},{"line_number":1207,"context_line":"        query \u003d query.outerjoin(models_v2.Subnet,"},{"line_number":1208,"context_line":"            models_v2.Subnet.network_id \u003d\u003d models_v2.Port.network_id)"},{"line_number":1209,"context_line":"        query \u003d query.filter(models_v2.Subnet.ip_version \u003d\u003d 4)"},{"line_number":1210,"context_line":"        query \u003d query.outerjoin(models_v2.SubnetPool,"},{"line_number":1211,"context_line":"            models_v2.Subnet.subnetpool_id \u003d\u003d models_v2.SubnetPool.id)"},{"line_number":1212,"context_line":""}],"source_content_type":"text/x-python","patch_set":20,"id":"9a8ffd7b_38dee96d","line":1209,"in_reply_to":"ba8a016a_869f814f","updated":"2015-12-02 00:05:28.000000000","message":"How does this change anything in that regard?  ;)","commit_id":"1c9681bc77ef12453fa6fb239635a999732c240a"},{"author":{"_account_id":261,"name":"Salvatore Orlando","email":"salv.orlando@gmail.com","username":"salvatore-orlando"},"change_message_id":"3bce4905e7d7b407836cb6132ca7c1adf93347d4","unresolved":false,"context_lines":[{"line_number":1208,"context_line":"            models_v2.Subnet.network_id \u003d\u003d models_v2.Port.network_id)"},{"line_number":1209,"context_line":"        query \u003d query.filter(models_v2.Subnet.ip_version \u003d\u003d 4)"},{"line_number":1210,"context_line":"        query \u003d query.outerjoin(models_v2.SubnetPool,"},{"line_number":1211,"context_line":"            models_v2.Subnet.subnetpool_id \u003d\u003d models_v2.SubnetPool.id)"},{"line_number":1212,"context_line":""},{"line_number":1213,"context_line":"        # Filter out on router_ids"},{"line_number":1214,"context_line":"        query \u003d query.filter(FloatingIP.router_id.in_(router_ids))"}],"source_content_type":"text/x-python","patch_set":23,"id":"9a8ffd7b_e3305558","line":1211,"updated":"2015-12-03 11:54:40.000000000","message":"just a question on the last two joins. why did you have to go for an outer join?\nIn this way you\u0027re also getting subnets which might or might now have an ip address on that specific port.\n\nAs you said, you can consider a join through IPAllocation. But then you would have to do either an extra join or sacrifice the ip_version filtering.\nMy personal opinion is that:\n1) doing the join via IPallocation makes a lot more sense\n2) I hate doing an extra join though\n3) filtering based on ip_version can easily be done in python. But then we will have to fetch more records than necessary for dual stack subnets.","commit_id":"f3bb22b0972959c2b0e174abdf01b69625252628"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"089f4ab3945c481725317becf3bd7631f8ffa359","unresolved":false,"context_lines":[{"line_number":12,"context_line":"#    License for the specific language governing permissions and limitations"},{"line_number":13,"context_line":"#    under the License."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"import itertools"},{"line_number":16,"context_line":"import netaddr"},{"line_number":17,"context_line":"from oslo_log import log as logging"},{"line_number":18,"context_line":"from oslo_utils import uuidutils"}],"source_content_type":"text/x-python","patch_set":27,"id":"7a740942_6d69bc8b","line":15,"updated":"2015-12-13 07:46:58.000000000","message":"minor nit but missing a newline here\nitertools should not be in the thrid party section","commit_id":"b63c4188f2571e0ac7984dc89fb1aae5fe3d451c"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"c732bd4194906575e3b1d98770fe066acd6ee7ed","unresolved":false,"context_lines":[{"line_number":12,"context_line":"#    License for the specific language governing permissions and limitations"},{"line_number":13,"context_line":"#    under the License."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"import itertools"},{"line_number":16,"context_line":"import netaddr"},{"line_number":17,"context_line":"from oslo_log import log as logging"},{"line_number":18,"context_line":"from oslo_utils import uuidutils"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a7e1126_9f191c7c","line":15,"in_reply_to":"7a740942_6d69bc8b","updated":"2015-12-21 21:09:36.000000000","message":"Done","commit_id":"b63c4188f2571e0ac7984dc89fb1aae5fe3d451c"},{"author":{"_account_id":261,"name":"Salvatore Orlando","email":"salv.orlando@gmail.com","username":"salvatore-orlando"},"change_message_id":"0f7ec97f373a945b597f74a513684fdf9f3234a4","unresolved":false,"context_lines":[{"line_number":12,"context_line":"#    License for the specific language governing permissions and limitations"},{"line_number":13,"context_line":"#    under the License."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"import itertools"},{"line_number":16,"context_line":"import netaddr"},{"line_number":17,"context_line":"from oslo_log import log as logging"},{"line_number":18,"context_line":"from oslo_utils import uuidutils"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a7e1126_c3c0b852","line":15,"in_reply_to":"7a740942_6d69bc8b","updated":"2015-12-21 10:55:04.000000000","message":"I did not know that.\nI thought it was part of the python library, or at least I inferred it from this: https://docs.python.org/2/library/itertools.html","commit_id":"b63c4188f2571e0ac7984dc89fb1aae5fe3d451c"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"089f4ab3945c481725317becf3bd7631f8ffa359","unresolved":false,"context_lines":[{"line_number":1195,"context_line":""},{"line_number":1196,"context_line":"    def _make_floatingip_dict_with_scope(self, floatingip_db, scope_id):"},{"line_number":1197,"context_line":"        d \u003d self._make_floatingip_dict(floatingip_db)"},{"line_number":1198,"context_line":"        d[\u0027fixed_ip_address_scope\u0027] \u003d scope_id"},{"line_number":1199,"context_line":"        return d"},{"line_number":1200,"context_line":""},{"line_number":1201,"context_line":"    def _get_sync_floating_ips(self, context, router_ids):"}],"source_content_type":"text/x-python","patch_set":27,"id":"7a740942_2d2df445","line":1198,"range":{"start_line":1198,"start_character":11,"end_line":1198,"end_character":33},"updated":"2015-12-13 07:46:58.000000000","message":"so here we are also sending the \u0027fixed_ip_address_scope\u0027 as part of the data to the agent. this requires a message version update.","commit_id":"b63c4188f2571e0ac7984dc89fb1aae5fe3d451c"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"c732bd4194906575e3b1d98770fe066acd6ee7ed","unresolved":false,"context_lines":[{"line_number":1195,"context_line":""},{"line_number":1196,"context_line":"    def _make_floatingip_dict_with_scope(self, floatingip_db, scope_id):"},{"line_number":1197,"context_line":"        d \u003d self._make_floatingip_dict(floatingip_db)"},{"line_number":1198,"context_line":"        d[\u0027fixed_ip_address_scope\u0027] \u003d scope_id"},{"line_number":1199,"context_line":"        return d"},{"line_number":1200,"context_line":""},{"line_number":1201,"context_line":"    def _get_sync_floating_ips(self, context, router_ids):"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a7e1126_dbae432d","line":1198,"in_reply_to":"3a7e1126_23a73cab","updated":"2015-12-21 21:09:36.000000000","message":"New version coming soon...","commit_id":"b63c4188f2571e0ac7984dc89fb1aae5fe3d451c"},{"author":{"_account_id":261,"name":"Salvatore Orlando","email":"salv.orlando@gmail.com","username":"salvatore-orlando"},"change_message_id":"0f7ec97f373a945b597f74a513684fdf9f3234a4","unresolved":false,"context_lines":[{"line_number":1195,"context_line":""},{"line_number":1196,"context_line":"    def _make_floatingip_dict_with_scope(self, floatingip_db, scope_id):"},{"line_number":1197,"context_line":"        d \u003d self._make_floatingip_dict(floatingip_db)"},{"line_number":1198,"context_line":"        d[\u0027fixed_ip_address_scope\u0027] \u003d scope_id"},{"line_number":1199,"context_line":"        return d"},{"line_number":1200,"context_line":""},{"line_number":1201,"context_line":"    def _get_sync_floating_ips(self, context, router_ids):"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a7e1126_23a73cab","line":1198,"in_reply_to":"3a7e1126_3aefd688","updated":"2015-12-21 10:55:04.000000000","message":"I agree with Carl\u0027s statement and that\u0027s why I did not give a -1, but processes should be respected and therefore we need the version bump, even if rolling upgrades won\u0027t be affected.","commit_id":"b63c4188f2571e0ac7984dc89fb1aae5fe3d451c"},{"author":{"_account_id":1131,"name":"Brian Haley","email":"haleyb.dev@gmail.com","username":"brian-haley"},"change_message_id":"2041c50acb2c49fcd79164db49e127ee72ee091c","unresolved":false,"context_lines":[{"line_number":1195,"context_line":""},{"line_number":1196,"context_line":"    def _make_floatingip_dict_with_scope(self, floatingip_db, scope_id):"},{"line_number":1197,"context_line":"        d \u003d self._make_floatingip_dict(floatingip_db)"},{"line_number":1198,"context_line":"        d[\u0027fixed_ip_address_scope\u0027] \u003d scope_id"},{"line_number":1199,"context_line":"        return d"},{"line_number":1200,"context_line":""},{"line_number":1201,"context_line":"    def _get_sync_floating_ips(self, context, router_ids):"}],"source_content_type":"text/x-python","patch_set":27,"id":"3a7e1126_3aefd688","line":1198,"in_reply_to":"5a710552_3373d04f","updated":"2015-12-17 16:06:47.000000000","message":"After looking through the tree I\u0027d agree with Gary, see get_device_details in neutron/plugins/ml2/rpc.py - version 1.3 added two elements to the port dict being returned for DVR and bumped the version.\n\nAlthough when the qos code added things the version wasn\u0027t bumped, so perhaps this code is fine?\n\nI have to admit I\u0027m confused now.","commit_id":"b63c4188f2571e0ac7984dc89fb1aae5fe3d451c"},{"author":{"_account_id":7448,"name":"Carl Baldwin","email":"carl@ecbaldwin.net","username":"carl-baldwin"},"change_message_id":"ff6fde62bdcc685f04915194540d53b544367eb7","unresolved":false,"context_lines":[{"line_number":1195,"context_line":""},{"line_number":1196,"context_line":"    def _make_floatingip_dict_with_scope(self, floatingip_db, scope_id):"},{"line_number":1197,"context_line":"        d \u003d self._make_floatingip_dict(floatingip_db)"},{"line_number":1198,"context_line":"        d[\u0027fixed_ip_address_scope\u0027] \u003d scope_id"},{"line_number":1199,"context_line":"        return d"},{"line_number":1200,"context_line":""},{"line_number":1201,"context_line":"    def _get_sync_floating_ips(self, context, router_ids):"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a710552_3373d04f","line":1198,"in_reply_to":"7a740942_2d2df445","updated":"2015-12-14 17:59:52.000000000","message":"I can add this.  I guess I never did because either side (server or agent) would handle the change in format from the other side gracefully without a version bump.  I actually thought a version bump might even make it less graceful.  Anyway, I never followed up on that thought.","commit_id":"b63c4188f2571e0ac7984dc89fb1aae5fe3d451c"}]}
