)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":8873,"name":"Assaf Muller","email":"amuller@redhat.com","username":"amuller"},"change_message_id":"cd8f35d8e9b578900e1be5293713e19531001dc8","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     AKamyshnikova \u003cakamyshnikova@mirantis.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-08-22 22:00:44 +0300"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[WIP] Check for ha port to become ACTIVE"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"After reboot of the node routers can be processed by l3 agent before"},{"line_number":10,"context_line":"openvswitch agent sets up appropriate ha ports, for such case add"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"1ac06dbe_e7f71a57","line":7,"updated":"2016-08-22 19:12:53.000000000","message":"This is much more promising :)","commit_id":"40810489b586bcc9a5ecb0e58cd30e59b55bfb72"},{"author":{"_account_id":1131,"name":"Brian Haley","email":"haleyb.dev@gmail.com","username":"brian-haley"},"change_message_id":"7774fa2384433c14a6295122c6db4cbe93e94417","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     venkata anil \u003canilvenkata@redhat.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-08-24 10:49:17 +0000"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[WIP] Check for ha port to become ACTIVE"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"After reboot of the node routers can be processed by l3 agent before"},{"line_number":10,"context_line":"openvswitch agent sets up appropriate ha ports, for such case add"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"1ac06dbe_0df907c9","line":7,"updated":"2016-08-25 02:24:02.000000000","message":"need to remove WIP","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"309386c851056e17d342b0c4c79dacdf06de6a6e","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     venkata anil \u003canilvenkata@redhat.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-08-24 10:49:17 +0000"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[WIP] Check for ha port to become ACTIVE"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"After reboot of the node routers can be processed by l3 agent before"},{"line_number":10,"context_line":"openvswitch agent sets up appropriate ha ports, for such case add"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"1ac06dbe_df2e6341","line":7,"in_reply_to":"1ac06dbe_0df907c9","updated":"2016-08-25 09:16:20.000000000","message":"I am testing this change locally","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":1131,"name":"Brian Haley","email":"haleyb.dev@gmail.com","username":"brian-haley"},"change_message_id":"7774fa2384433c14a6295122c6db4cbe93e94417","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"After reboot of the node routers can be processed by l3 agent before"},{"line_number":10,"context_line":"openvswitch agent sets up appropriate ha ports, for such case add"},{"line_number":11,"context_line":"check status of ha port."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Closes-bug: #1597461"},{"line_number":14,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"1ac06dbe_4d1adf18","line":11,"updated":"2016-08-25 02:24:02.000000000","message":"This isn\u0027t just after a reboot, right?  Unless my comment in the bug was wrong?","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"309386c851056e17d342b0c4c79dacdf06de6a6e","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"After reboot of the node routers can be processed by l3 agent before"},{"line_number":10,"context_line":"openvswitch agent sets up appropriate ha ports, for such case add"},{"line_number":11,"context_line":"check status of ha port."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Closes-bug: #1597461"},{"line_number":14,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"1ac06dbe_bff28798","line":11,"in_reply_to":"1ac06dbe_0289d1ca","updated":"2016-08-25 09:16:20.000000000","message":"Probably you hit the bug Dongcan points, as this problem appear with restart of both l3 and l2 agents and reboot, and any recover of this two agents.","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"2a8c73c2f31507ee987129e400ae20c251762db5","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"After reboot of the node routers can be processed by l3 agent before"},{"line_number":10,"context_line":"openvswitch agent sets up appropriate ha ports, for such case add"},{"line_number":11,"context_line":"check status of ha port."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Closes-bug: #1597461"},{"line_number":14,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"1ac06dbe_0289d1ca","line":11,"in_reply_to":"1ac06dbe_4d1adf18","updated":"2016-08-25 04:32:11.000000000","message":"@Brian Haley, I saw your comment in launchpad, it looks same as https://bugs.launchpad.net/neutron/+bug/1602320. And Ann\u0027s bug is related to agent restart.","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"ae0b4e30275adb831fab8289c9add60ccb502416","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"After reboot of the node routers can be processed by l3 agent before"},{"line_number":10,"context_line":"openvswitch agent sets up appropriate ha ports, for such case add"},{"line_number":11,"context_line":"check status of ha port."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Closes-bug: #1597461"},{"line_number":14,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"1ac06dbe_f7c9c326","line":11,"in_reply_to":"1ac06dbe_bff28798","updated":"2016-08-25 09:58:09.000000000","message":"Also when HA router is created(i.e when HA network ports created).","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"}],"neutron/agent/l3/ha_router.py":[{"author":{"_account_id":8873,"name":"Assaf Muller","email":"amuller@redhat.com","username":"amuller"},"change_message_id":"7c12b52b4ea0ce150da0061a5a13c72ed45d6e1f","unresolved":false,"context_lines":[{"line_number":75,"context_line":"    def ha_namespace(self):"},{"line_number":76,"context_line":"        return self.ns_name"},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    def wait_for_active_ha_port(self):"},{"line_number":79,"context_line":"        id \u003d self.ha_port[\u0027id\u0027]"},{"line_number":80,"context_line":"        def predicate():"},{"line_number":81,"context_line":"            status \u003d self.agent.get_ha_port(port_id\u003did)[\u0027status\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_bb5a694e","line":78,"updated":"2016-08-22 15:41:36.000000000","message":"I don\u0027t think this is a valid solution, it\u0027s not scalable... As John said for a setup with 3 controllers and 1,000 routers, restarting the control plane will trigger 3000 RPC+DB calls every second.\n\nWe can investigate an approach that would bulk call all HA ports for all HA routers known to the agent and use the L3 agent queue to make sure routers aren\u0027t processed until the ports are ready, that would reduce this from an O(n) to O(1), but increase complexity. Still I think that\u0027d be a better solution than what I had in mind previously which was a Unix domain socket and messaging system between the OVS and L3 agents locally to the node.","commit_id":"cf681a1982be78fd7f546f350a126464ae83155f"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"03f9cf294bde89a89ce4ce21c05d91ba34497064","unresolved":false,"context_lines":[{"line_number":81,"context_line":"            status \u003d self.agent.get_ha_port(port_id\u003did)[\u0027status\u0027]"},{"line_number":82,"context_line":"            return status \u003d\u003d n_consts.ACTIVE"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        common_utils.wait_until_true(predicate)"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def initialize(self, process_monitor):"},{"line_number":87,"context_line":"        super(HaRouter, self).initialize(process_monitor)"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_b1501e60","line":84,"range":{"start_line":84,"start_character":8,"end_line":84,"end_character":47},"updated":"2016-08-19 08:16:23.000000000","message":"This basically means that until the ha port is active, once per second, an RPC call will be made to the server. If the server is busy/overloaded with requests this can take more than 60 seconds to complete (and then this code will throw an exception) and if it doesn\u0027t it will spam the server with \u003cmax_ha_agents\u003e RPC requests per second.\n\nIsn\u0027t there a better way to do this?","commit_id":"cf681a1982be78fd7f546f350a126464ae83155f"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"3d9e89fdbb48f11dce8d8047355833aff7f9d704","unresolved":false,"context_lines":[{"line_number":81,"context_line":"            status \u003d self.agent.get_ha_port(port_id\u003did)[\u0027status\u0027]"},{"line_number":82,"context_line":"            return status \u003d\u003d n_consts.ACTIVE"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        common_utils.wait_until_true(predicate)"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def initialize(self, process_monitor):"},{"line_number":87,"context_line":"        super(HaRouter, self).initialize(process_monitor)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_d518ed86","line":84,"range":{"start_line":84,"start_character":8,"end_line":84,"end_character":47},"in_reply_to":"1ac06dbe_345c2725","updated":"2016-08-22 09:39:04.000000000","message":"@John\ncan u please explain how it triggers get_router_ids?\n\n@Ann\nyou can override _notify_l3_agent_port_update in ha module, so that u can avoid subscribe() again in ha module.","commit_id":"cf681a1982be78fd7f546f350a126464ae83155f"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"5f22df56e986ac2acc8e53efcd9c4582834392da","unresolved":false,"context_lines":[{"line_number":81,"context_line":"            status \u003d self.agent.get_ha_port(port_id\u003did)[\u0027status\u0027]"},{"line_number":82,"context_line":"            return status \u003d\u003d n_consts.ACTIVE"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        common_utils.wait_until_true(predicate)"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def initialize(self, process_monitor):"},{"line_number":87,"context_line":"        super(HaRouter, self).initialize(process_monitor)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_345c2725","line":84,"range":{"start_line":84,"start_character":8,"end_line":84,"end_character":47},"in_reply_to":"1ac06dbe_cf2a637e","updated":"2016-08-19 15:55:22.000000000","message":"As a side effect, this will trigger get_router_ids() (and thus the auto_schedule_routers), which opens this up for racefulness.\n\nThe optimal solution will be, in my eyes, to only send the initial \"router_updated\" (the one that happens after the scheduling is complete) AFTER we\u0027ve received the port_status_change event. But this is a way overkill.","commit_id":"cf681a1982be78fd7f546f350a126464ae83155f"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"60b318737c30e93d336dd2c3735b0b49220b9e52","unresolved":false,"context_lines":[{"line_number":81,"context_line":"            status \u003d self.agent.get_ha_port(port_id\u003did)[\u0027status\u0027]"},{"line_number":82,"context_line":"            return status \u003d\u003d n_consts.ACTIVE"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        common_utils.wait_until_true(predicate)"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def initialize(self, process_monitor):"},{"line_number":87,"context_line":"        super(HaRouter, self).initialize(process_monitor)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_af3fddd4","line":84,"range":{"start_line":84,"start_character":8,"end_line":84,"end_character":47},"in_reply_to":"1ac06dbe_d518ed86","updated":"2016-08-22 10:24:45.000000000","message":"Sorry - upon looking at the code, it looks like I\u0027m wrong - the suggestion Anil made will trigger sync_routers (which does not invoke auto_schedule_routers, unlike get_router_ids), hence no contention in his solution.","commit_id":"cf681a1982be78fd7f546f350a126464ae83155f"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"bc02859806dabf098033bef4a8118945225b4360","unresolved":false,"context_lines":[{"line_number":81,"context_line":"            status \u003d self.agent.get_ha_port(port_id\u003did)[\u0027status\u0027]"},{"line_number":82,"context_line":"            return status \u003d\u003d n_consts.ACTIVE"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        common_utils.wait_until_true(predicate)"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def initialize(self, process_monitor):"},{"line_number":87,"context_line":"        super(HaRouter, self).initialize(process_monitor)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_cf2a637e","line":84,"range":{"start_line":84,"start_character":8,"end_line":84,"end_character":47},"in_reply_to":"1ac06dbe_d8934f4e","updated":"2016-08-19 15:03:40.000000000","message":"Thank you!\n\nI will check this approach and push update in next patch set.","commit_id":"cf681a1982be78fd7f546f350a126464ae83155f"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"2ed0a3e1b84e780e37d2897866e9efa70cbc4cb7","unresolved":false,"context_lines":[{"line_number":81,"context_line":"            status \u003d self.agent.get_ha_port(port_id\u003did)[\u0027status\u0027]"},{"line_number":82,"context_line":"            return status \u003d\u003d n_consts.ACTIVE"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        common_utils.wait_until_true(predicate)"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def initialize(self, process_monitor):"},{"line_number":87,"context_line":"        super(HaRouter, self).initialize(process_monitor)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_d8934f4e","line":84,"range":{"start_line":84,"start_character":8,"end_line":84,"end_character":47},"in_reply_to":"3ac371cc_3c16c5a7","updated":"2016-08-19 14:09:56.000000000","message":"you can get router_update notification for port_status_change. For that, you can update the patch like below instead of \"wait_for_active_ha_port\".\n\n1) l3_hamode_db (or any ha module in plugin side)  has to subscribe for port_update notification, like [1]\n2) when ha network port\u0027s status on agent becomes active, l3_hamode_db will get notification becuase of [2]\n3) in your new ha handler function(for example like [3]), you can check for port status is active, if active call routers_updated_on_host(like [4])\n4) in agent, u will get router( with ha network interface port updated to active) [5]\n5) then, call enable_keepalived only if self.ha_port[\u0027status\u0027] \u003d\u003d \u0027ACTIVE\u0027 [6]\n\n[1] https://github.com/openstack/neutron/blob/master/neutron/db/l3_dvrscheduler_db.py#L498\n[2] https://github.com/openstack/neutron/blob/master/neutron/plugins/ml2/plugin.py#L1729\n[3] https://github.com/openstack/neutron/blob/master/neutron/db/l3_dvrscheduler_db.py#L400\n[4] https://github.com/openstack/neutron/blob/master/neutron/db/l3_dvrscheduler_db.py#L434\n[5] https://github.com/openstack/neutron/blob/master/neutron/agent/l3/agent.py#L442\n[6] https://github.com/openstack/neutron/blob/master/neutron/agent/l3/ha_router.py#L388","commit_id":"cf681a1982be78fd7f546f350a126464ae83155f"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"6482798c2a74e8ff4c75d04cd4eb71a737386da4","unresolved":false,"context_lines":[{"line_number":81,"context_line":"            status \u003d self.agent.get_ha_port(port_id\u003did)[\u0027status\u0027]"},{"line_number":82,"context_line":"            return status \u003d\u003d n_consts.ACTIVE"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        common_utils.wait_until_true(predicate)"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def initialize(self, process_monitor):"},{"line_number":87,"context_line":"        super(HaRouter, self).initialize(process_monitor)"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_3c16c5a7","line":84,"range":{"start_line":84,"start_character":8,"end_line":84,"end_character":47},"in_reply_to":"3ac371cc_b1501e60","updated":"2016-08-19 08:34:21.000000000","message":"Yes, this is weak point of this approach. \n\nI guess the other way for agent to just wait until ha port become active, so the l3 agent should just receive message about it.","commit_id":"cf681a1982be78fd7f546f350a126464ae83155f"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"7af85f3f73938b042a386bb214f5826668bec81d","unresolved":false,"context_lines":[{"line_number":387,"context_line":"        super(HaRouter, self).process(agent)"},{"line_number":388,"context_line":""},{"line_number":389,"context_line":"        if (self.ha_port and"},{"line_number":390,"context_line":"                    self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":391,"context_line":"            self.enable_keepalived()"},{"line_number":392,"context_line":""},{"line_number":393,"context_line":"    @common_utils.synchronized(\u0027enable_radvd\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_f2bcc807","line":390,"range":{"start_line":390,"start_character":8,"end_line":390,"end_character":20},"updated":"2016-08-23 12:37:36.000000000","message":"Indent","commit_id":"40810489b586bcc9a5ecb0e58cd30e59b55bfb72"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"f2386d196f78244c58e43c5b0fc3185ad927765a","unresolved":false,"context_lines":[{"line_number":128,"context_line":"        shutil.rmtree(conf_dir)"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"    def _get_keepalived_instance(self):"},{"line_number":131,"context_line":"        return self.keepalived_manager.config.get_instance(self.ha_vr_id)"},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"    def _get_primary_vip(self):"},{"line_number":134,"context_line":"        return self._get_keepalived_instance().get_primary_vip()"}],"source_content_type":"text/x-python","patch_set":3,"id":"1ac06dbe_66401535","line":131,"updated":"2016-08-23 14:40:28.000000000","message":"Unrelated change.","commit_id":"00d495663bcef707eb17294f062cef92676fa781"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"4714cc8db5c230a19f916a9631c2db003d63178b","unresolved":false,"context_lines":[{"line_number":128,"context_line":"        shutil.rmtree(conf_dir)"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"    def _get_keepalived_instance(self):"},{"line_number":131,"context_line":"        return self.keepalived_manager.config.get_instance(self.ha_vr_id)"},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"    def _get_primary_vip(self):"},{"line_number":134,"context_line":"        return self._get_keepalived_instance().get_primary_vip()"}],"source_content_type":"text/x-python","patch_set":3,"id":"1ac06dbe_f7ef8d84","line":131,"in_reply_to":"1ac06dbe_66401535","updated":"2016-08-23 14:52:12.000000000","message":"Done","commit_id":"00d495663bcef707eb17294f062cef92676fa781"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"bc7ce2866cfb316c8de41e815ee55aa773483b69","unresolved":false,"context_lines":[{"line_number":314,"context_line":""},{"line_number":315,"context_line":"        return callback"},{"line_number":316,"context_line":""},{"line_number":317,"context_line":"    def spawn_state_change_monitor(self, process_monitor):"},{"line_number":318,"context_line":"        if (self.ha_port and"},{"line_number":319,"context_line":"                self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":320,"context_line":"            pm \u003d self._get_state_change_monitor_process_manager()"}],"source_content_type":"text/x-python","patch_set":3,"id":"1ac06dbe_8b8b9ac2","line":317,"updated":"2016-08-23 14:34:17.000000000","message":"I think no need to check for ha_port here. We will spawn state_change_monitor during initialize() itself.\n\nAs keepalived process is not spawned during initialize(), ip monitor won\u0027t see primary vip changes, and wont notify neutron about state change.","commit_id":"00d495663bcef707eb17294f062cef92676fa781"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"24206ca86774f7aed77bc33bfd15628c54898a43","unresolved":false,"context_lines":[{"line_number":314,"context_line":""},{"line_number":315,"context_line":"        return callback"},{"line_number":316,"context_line":""},{"line_number":317,"context_line":"    def spawn_state_change_monitor(self, process_monitor):"},{"line_number":318,"context_line":"        if (self.ha_port and"},{"line_number":319,"context_line":"                self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":320,"context_line":"            pm \u003d self._get_state_change_monitor_process_manager()"}],"source_content_type":"text/x-python","patch_set":3,"id":"1ac06dbe_614abf27","line":317,"in_reply_to":"1ac06dbe_8b8b9ac2","updated":"2016-08-23 14:45:31.000000000","message":"neutron-keepalived-state-change will be monitoring for addition or deletion of 169.254.0.1/24 address on ha-xxx interface. But this addition or deletion is done by keepalived. When keepalived is not running, I think neutron-keepalived-state-change won\u0027t see  169.254.0.1 addition/deletion  and will be idle.\n\nLet me test this and confirm.","commit_id":"00d495663bcef707eb17294f062cef92676fa781"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a957289241497276ea9351c2a7c675adcb82754b","unresolved":false,"context_lines":[{"line_number":316,"context_line":"        return callback"},{"line_number":317,"context_line":""},{"line_number":318,"context_line":"    def spawn_state_change_monitor(self, process_monitor):"},{"line_number":319,"context_line":"        if (self.ha_port and"},{"line_number":320,"context_line":"                self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":321,"context_line":"            pm \u003d self._get_state_change_monitor_process_manager()"},{"line_number":322,"context_line":"            pm.enable()"},{"line_number":323,"context_line":"            process_monitor.register("}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_5e8e792e","line":320,"range":{"start_line":319,"start_character":8,"end_line":320,"end_character":71},"updated":"2016-08-23 15:07:34.000000000","message":"This may introduce a race condition.\nWhat if HA port is not active, but a HA router delete RPC comes.\nThen what will happen in Line 383 ?\n\nThe following patch deal with something about that.\nhttps://review.openstack.org/265672","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"},{"author":{"_account_id":8873,"name":"Assaf Muller","email":"amuller@redhat.com","username":"amuller"},"change_message_id":"4b07b6c52f0378cb9d10c12cf411fb1b5b0bfaaf","unresolved":false,"context_lines":[{"line_number":387,"context_line":"    def process(self, agent):"},{"line_number":388,"context_line":"        super(HaRouter, self).process(agent)"},{"line_number":389,"context_line":""},{"line_number":390,"context_line":"        if (self.ha_port and"},{"line_number":391,"context_line":"                self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":392,"context_line":"            self.enable_keepalived()"},{"line_number":393,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_59f4bc59","line":390,"updated":"2016-08-23 20:46:20.000000000","message":"I\u0027ve found the bug that I think is failing the fullstack test (And demonstrates why we need a functional test). self.ha_port is assigned in the initialize function, which is only called for *new* routers, not updated routers. So when you check the condition in line 391 it\u0027s using stale data, and \u0027status\u0027 will never be ACTIVE here.","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"0b0611117f18ca4462725707b35e622a34e32a3b","unresolved":false,"context_lines":[{"line_number":387,"context_line":"    def process(self, agent):"},{"line_number":388,"context_line":"        super(HaRouter, self).process(agent)"},{"line_number":389,"context_line":""},{"line_number":390,"context_line":"        if (self.ha_port and"},{"line_number":391,"context_line":"                self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":392,"context_line":"            self.enable_keepalived()"},{"line_number":393,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_f46122d4","line":390,"in_reply_to":"1ac06dbe_59f4bc59","updated":"2016-08-24 02:36:27.000000000","message":"Agreed, the self.ha_port[\u0027status\u0027] will not be changed to \u0027ACTIVE\u0027 after the notification you added to l3_hascheduler_db.","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"20dc43e7935779acee4faa3187748da7ed2f256c","unresolved":false,"context_lines":[{"line_number":387,"context_line":"    def process(self, agent):"},{"line_number":388,"context_line":"        super(HaRouter, self).process(agent)"},{"line_number":389,"context_line":""},{"line_number":390,"context_line":"        if (self.ha_port and"},{"line_number":391,"context_line":"                self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":392,"context_line":"            self.enable_keepalived()"},{"line_number":393,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_b40200b2","line":390,"in_reply_to":"1ac06dbe_59f4bc59","updated":"2016-08-24 07:51:09.000000000","message":"agree.","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a957289241497276ea9351c2a7c675adcb82754b","unresolved":false,"context_lines":[{"line_number":387,"context_line":"    def process(self, agent):"},{"line_number":388,"context_line":"        super(HaRouter, self).process(agent)"},{"line_number":389,"context_line":""},{"line_number":390,"context_line":"        if (self.ha_port and"},{"line_number":391,"context_line":"                self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":392,"context_line":"            self.enable_keepalived()"},{"line_number":393,"context_line":""},{"line_number":394,"context_line":"    @common_utils.synchronized(\u0027enable_radvd\u0027)"}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_1e71a144","line":391,"range":{"start_line":390,"start_character":8,"end_line":391,"end_character":71},"updated":"2016-08-23 15:07:34.000000000","message":"This may introduce a race condition.\nWhat if HA port is not active, but a HA router delete RPC comes.\nThen what will happen in Line 385 ?\n\nThe following patch deal with something about that.\nhttps://review.openstack.org/265672","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"fa12c58f6a076eec1fcbd63856fa5300110c549c","unresolved":false,"context_lines":[{"line_number":387,"context_line":"    def process(self, agent):"},{"line_number":388,"context_line":"        super(HaRouter, self).process(agent)"},{"line_number":389,"context_line":""},{"line_number":390,"context_line":"        if (self.ha_port and"},{"line_number":391,"context_line":"                self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":392,"context_line":"            self.enable_keepalived()"},{"line_number":393,"context_line":""},{"line_number":394,"context_line":"    @common_utils.synchronized(\u0027enable_radvd\u0027)"}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_b0b236e3","line":391,"range":{"start_line":390,"start_character":8,"end_line":391,"end_character":71},"in_reply_to":"1ac06dbe_1e71a144","updated":"2016-08-23 16:16:09.000000000","message":"At Line 385, it tries to kill keepalived process, but ignored as it is not running. Then it cleans up keepalived process manager and removes conf dir.\n\nI will check your patch. Thanks","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"c3ee4d6ead7ccc18711bda5d28ae07dfae23166d","unresolved":false,"context_lines":[{"line_number":387,"context_line":"    def process(self, agent):"},{"line_number":388,"context_line":"        super(HaRouter, self).process(agent)"},{"line_number":389,"context_line":""},{"line_number":390,"context_line":"        if (self.ha_port and"},{"line_number":391,"context_line":"                self.ha_port[\u0027status\u0027] \u003d\u003d n_consts.PORT_STATUS_ACTIVE):"},{"line_number":392,"context_line":"            self.enable_keepalived()"},{"line_number":393,"context_line":""},{"line_number":394,"context_line":"    @common_utils.synchronized(\u0027enable_radvd\u0027)"}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_747b727b","line":391,"range":{"start_line":390,"start_character":8,"end_line":391,"end_character":71},"in_reply_to":"1ac06dbe_b0b236e3","updated":"2016-08-24 02:37:45.000000000","message":"You may need to test this scenario.","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"}],"neutron/db/l3_hascheduler_db.py":[{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"7af85f3f73938b042a386bb214f5826668bec81d","unresolved":false,"context_lines":[{"line_number":91,"context_line":""},{"line_number":92,"context_line":"def _notify_l3_agent_port_update(resource, event, trigger, **kwargs):"},{"line_number":93,"context_line":"    new_port \u003d kwargs.get(\u0027port\u0027)"},{"line_number":94,"context_line":"    context \u003d kwargs[\u0027context\u0027]"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":"    if new_port:"},{"line_number":97,"context_line":"        new_device_owner \u003d new_port.get(\u0027device_owner\u0027, \u0027\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_72a3b800","line":94,"range":{"start_line":94,"start_character":4,"end_line":94,"end_character":31},"updated":"2016-08-23 12:37:36.000000000","message":"This sounds like context is always preset so it can be part of parameters on L92.","commit_id":"40810489b586bcc9a5ecb0e58cd30e59b55bfb72"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"7af85f3f73938b042a386bb214f5826668bec81d","unresolved":false,"context_lines":[{"line_number":96,"context_line":"    if new_port:"},{"line_number":97,"context_line":"        new_device_owner \u003d new_port.get(\u0027device_owner\u0027, \u0027\u0027)"},{"line_number":98,"context_line":"        l3plugin \u003d manager.NeutronManager.get_service_plugins().get("},{"line_number":99,"context_line":"                service_constants.L3_ROUTER_NAT)"},{"line_number":100,"context_line":""},{"line_number":101,"context_line":"        if (new_device_owner \u003d\u003d \u0027network:router_ha_interface\u0027 and"},{"line_number":102,"context_line":"                    new_port[\u0027status\u0027] \u003d\u003d \u0027ACTIVE\u0027):"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_32d2e05c","line":99,"range":{"start_line":99,"start_character":8,"end_line":99,"end_character":16},"updated":"2016-08-23 12:37:36.000000000","message":"Indent","commit_id":"40810489b586bcc9a5ecb0e58cd30e59b55bfb72"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"7af85f3f73938b042a386bb214f5826668bec81d","unresolved":false,"context_lines":[{"line_number":100,"context_line":""},{"line_number":101,"context_line":"        if (new_device_owner \u003d\u003d \u0027network:router_ha_interface\u0027 and"},{"line_number":102,"context_line":"                    new_port[\u0027status\u0027] \u003d\u003d \u0027ACTIVE\u0027):"},{"line_number":103,"context_line":"                l3plugin.l3_rpc_notifier.routers_updated("},{"line_number":104,"context_line":"                    context, [new_port[\u0027device_id\u0027]])"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":"def subscribe():"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_f28e8877","line":103,"range":{"start_line":103,"start_character":8,"end_line":103,"end_character":16},"updated":"2016-08-23 12:37:36.000000000","message":"Indent","commit_id":"40810489b586bcc9a5ecb0e58cd30e59b55bfb72"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"2b56e3cac0ee7ccb280bee328e9176e955734fd6","unresolved":false,"context_lines":[{"line_number":100,"context_line":""},{"line_number":101,"context_line":"        if (new_device_owner \u003d\u003d \u0027network:router_ha_interface\u0027 and"},{"line_number":102,"context_line":"                    new_port[\u0027status\u0027] \u003d\u003d \u0027ACTIVE\u0027):"},{"line_number":103,"context_line":"                l3plugin.l3_rpc_notifier.routers_updated("},{"line_number":104,"context_line":"                    context, [new_port[\u0027device_id\u0027]])"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":"def subscribe():"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_e2c38855","line":103,"updated":"2016-08-22 19:29:18.000000000","message":"port will always have host_id when status changed to active.\n\noriginal_port \u003d kwargs.get(\u0027original_port\u0027)\nhost \u003d new_port[portbindings.HOST_ID]\nif (new_device_owner \u003d\u003d \u0027network:router_ha_interface\u0027 and \n    host and \n    new_port[\u0027status\u0027] \u003d\u003d \u0027ACTIVE\u0027 and\n    original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027])\n    l3plugin.l3_rpc_notifier.routers_updated_on_host(\n        context, [new_port[\u0027device_id\u0027]], host)","commit_id":"40810489b586bcc9a5ecb0e58cd30e59b55bfb72"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"f2386d196f78244c58e43c5b0fc3185ad927765a","unresolved":false,"context_lines":[{"line_number":98,"context_line":"    if new_port and original_port and host:"},{"line_number":99,"context_line":"        new_device_owner \u003d new_port.get(\u0027device_owner\u0027, \u0027\u0027)"},{"line_number":100,"context_line":"        if (new_device_owner \u003d\u003d constants.DEVICE_OWNER_ROUTER_HA_INTF and"},{"line_number":101,"context_line":"            new_port[\u0027status\u0027] \u003d\u003d \u0027ACTIVE\u0027 and"},{"line_number":102,"context_line":"            original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027]):"},{"line_number":103,"context_line":"            l3plugin \u003d manager.NeutronManager.get_service_plugins().get("},{"line_number":104,"context_line":"                service_constants.L3_ROUTER_NAT)"}],"source_content_type":"text/x-python","patch_set":3,"id":"1ac06dbe_265bbdf7","line":101,"range":{"start_line":101,"start_character":34,"end_line":101,"end_character":42},"updated":"2016-08-23 14:40:28.000000000","message":"This should use PORT_STATUS_ACTIVE from the constants.py file.","commit_id":"00d495663bcef707eb17294f062cef92676fa781"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"4714cc8db5c230a19f916a9631c2db003d63178b","unresolved":false,"context_lines":[{"line_number":98,"context_line":"    if new_port and original_port and host:"},{"line_number":99,"context_line":"        new_device_owner \u003d new_port.get(\u0027device_owner\u0027, \u0027\u0027)"},{"line_number":100,"context_line":"        if (new_device_owner \u003d\u003d constants.DEVICE_OWNER_ROUTER_HA_INTF and"},{"line_number":101,"context_line":"            new_port[\u0027status\u0027] \u003d\u003d \u0027ACTIVE\u0027 and"},{"line_number":102,"context_line":"            original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027]):"},{"line_number":103,"context_line":"            l3plugin \u003d manager.NeutronManager.get_service_plugins().get("},{"line_number":104,"context_line":"                service_constants.L3_ROUTER_NAT)"}],"source_content_type":"text/x-python","patch_set":3,"id":"1ac06dbe_d79b7116","line":101,"range":{"start_line":101,"start_character":34,"end_line":101,"end_character":42},"in_reply_to":"1ac06dbe_265bbdf7","updated":"2016-08-23 14:52:12.000000000","message":"Done","commit_id":"00d495663bcef707eb17294f062cef92676fa781"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"0daea045717658e52aa245fc2cd209611502e8fb","unresolved":false,"context_lines":[{"line_number":102,"context_line":"                original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027]):"},{"line_number":103,"context_line":"            l3plugin \u003d manager.NeutronManager.get_service_plugins().get("},{"line_number":104,"context_line":"                service_constants.L3_ROUTER_NAT)"},{"line_number":105,"context_line":"            l3plugin.l3_rpc_notifier.routers_updated_on_host("},{"line_number":106,"context_line":"                context, [new_port[\u0027device_id\u0027]], host)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"def subscribe():"},{"line_number":109,"context_line":"    registry.subscribe("}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_feb3e595","line":106,"range":{"start_line":105,"start_character":12,"end_line":106,"end_character":55},"updated":"2016-08-23 15:09:26.000000000","message":"Also here, what if the new_port[\u0027device_id\u0027], aka router_id, is concurrently deleted?","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"0b0611117f18ca4462725707b35e622a34e32a3b","unresolved":false,"context_lines":[{"line_number":102,"context_line":"                original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027]):"},{"line_number":103,"context_line":"            l3plugin \u003d manager.NeutronManager.get_service_plugins().get("},{"line_number":104,"context_line":"                service_constants.L3_ROUTER_NAT)"},{"line_number":105,"context_line":"            l3plugin.l3_rpc_notifier.routers_updated_on_host("},{"line_number":106,"context_line":"                context, [new_port[\u0027device_id\u0027]], host)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"def subscribe():"},{"line_number":109,"context_line":"    registry.subscribe("}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_d98d3fd4","line":106,"range":{"start_line":105,"start_character":12,"end_line":106,"end_character":55},"in_reply_to":"1ac06dbe_30012607","updated":"2016-08-24 02:36:27.000000000","message":"Then it may cause a series of redundant operations in L3 agent side, such as sync (self.plugin_rpc.get_routers) a router info which is already deleted, removing (_safe_router_removed) a router again which not in L3 agent.","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"fa12c58f6a076eec1fcbd63856fa5300110c549c","unresolved":false,"context_lines":[{"line_number":102,"context_line":"                original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027]):"},{"line_number":103,"context_line":"            l3plugin \u003d manager.NeutronManager.get_service_plugins().get("},{"line_number":104,"context_line":"                service_constants.L3_ROUTER_NAT)"},{"line_number":105,"context_line":"            l3plugin.l3_rpc_notifier.routers_updated_on_host("},{"line_number":106,"context_line":"                context, [new_port[\u0027device_id\u0027]], host)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"def subscribe():"},{"line_number":109,"context_line":"    registry.subscribe("}],"source_content_type":"text/x-python","patch_set":4,"id":"1ac06dbe_30012607","line":106,"range":{"start_line":105,"start_character":12,"end_line":106,"end_character":55},"in_reply_to":"1ac06dbe_feb3e595","updated":"2016-08-23 16:16:09.000000000","message":"When l3 agent calls sync_routers for routers_updated rpc(because of L105), sync_routers won\u0027t return router as it got deleted.","commit_id":"27c336ede16824a1d43c5e0461e8b42456515aed"},{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"2a8c73c2f31507ee987129e400ae20c251762db5","unresolved":false,"context_lines":[{"line_number":90,"context_line":"        return self._get_agents_dict_for_router(bindings)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"def _notify_l3_agent_port_update(resource, event, trigger, **kwargs):"},{"line_number":94,"context_line":"    new_port \u003d kwargs.get(\u0027port\u0027)"},{"line_number":95,"context_line":"    original_port \u003d kwargs.get(\u0027original_port\u0027)"},{"line_number":96,"context_line":"    context \u003d kwargs.get(\u0027context\u0027)"}],"source_content_type":"text/x-python","patch_set":7,"id":"1ac06dbe_62788590","line":93,"range":{"start_line":93,"start_character":4,"end_line":93,"end_character":32},"updated":"2016-08-25 04:32:11.000000000","message":"_notify_l3_agent_ha_port_update will be better.","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"309386c851056e17d342b0c4c79dacdf06de6a6e","unresolved":false,"context_lines":[{"line_number":90,"context_line":"        return self._get_agents_dict_for_router(bindings)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"def _notify_l3_agent_port_update(resource, event, trigger, **kwargs):"},{"line_number":94,"context_line":"    new_port \u003d kwargs.get(\u0027port\u0027)"},{"line_number":95,"context_line":"    original_port \u003d kwargs.get(\u0027original_port\u0027)"},{"line_number":96,"context_line":"    context \u003d kwargs.get(\u0027context\u0027)"}],"source_content_type":"text/x-python","patch_set":7,"id":"1ac06dbe_1f38fb3c","line":93,"range":{"start_line":93,"start_character":4,"end_line":93,"end_character":32},"in_reply_to":"1ac06dbe_62788590","updated":"2016-08-25 09:16:20.000000000","message":"Done","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":8873,"name":"Assaf Muller","email":"amuller@redhat.com","username":"amuller"},"change_message_id":"caff07647d1aa26a3357c75a0e975524e25735c1","unresolved":false,"context_lines":[{"line_number":98,"context_line":""},{"line_number":99,"context_line":"    if new_port and original_port and host:"},{"line_number":100,"context_line":"        new_device_owner \u003d new_port.get(\u0027device_owner\u0027, \u0027\u0027)"},{"line_number":101,"context_line":"        if (new_device_owner \u003d\u003d constants.DEVICE_OWNER_ROUTER_HA_INTF and"},{"line_number":102,"context_line":"            new_port[\u0027status\u0027] \u003d\u003d constants.PORT_STATUS_ACTIVE and"},{"line_number":103,"context_line":"            original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027]):"},{"line_number":104,"context_line":"            l3plugin \u003d manager.NeutronManager.get_service_plugins().get("}],"source_content_type":"text/x-python","patch_set":8,"id":"fa7ab95a_062d0f46","line":101,"updated":"2016-08-26 22:16:02.000000000","message":"Sorry doesn\u0027t this need to be for both SNAT ports (For HA+DVR) routers as well as HA ports?","commit_id":"64239f612699170e65f9a21ff40ba44b075eaab6"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"992cc75822a68b286668c6b6e22928ba5c5137f7","unresolved":false,"context_lines":[{"line_number":98,"context_line":""},{"line_number":99,"context_line":"    if new_port and original_port and host:"},{"line_number":100,"context_line":"        new_device_owner \u003d new_port.get(\u0027device_owner\u0027, \u0027\u0027)"},{"line_number":101,"context_line":"        if (new_device_owner \u003d\u003d constants.DEVICE_OWNER_ROUTER_HA_INTF and"},{"line_number":102,"context_line":"            new_port[\u0027status\u0027] \u003d\u003d constants.PORT_STATUS_ACTIVE and"},{"line_number":103,"context_line":"            original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027]):"},{"line_number":104,"context_line":"            l3plugin \u003d manager.NeutronManager.get_service_plugins().get("}],"source_content_type":"text/x-python","patch_set":8,"id":"fa7ab95a_956919c1","line":101,"in_reply_to":"fa7ab95a_062d0f46","updated":"2016-08-29 11:29:25.000000000","message":"Hm... I\u0027m confused. Here we check for HA port to be become ACTIVE in order to enable keepalived only when it will be able to communicate with other keepalived instances. How SNAT ports are related to this?","commit_id":"64239f612699170e65f9a21ff40ba44b075eaab6"},{"author":{"_account_id":8873,"name":"Assaf Muller","email":"amuller@redhat.com","username":"amuller"},"change_message_id":"1aea53f3eee0ad08d6d09433d5b29c961e73dd17","unresolved":false,"context_lines":[{"line_number":98,"context_line":""},{"line_number":99,"context_line":"    if new_port and original_port and host:"},{"line_number":100,"context_line":"        new_device_owner \u003d new_port.get(\u0027device_owner\u0027, \u0027\u0027)"},{"line_number":101,"context_line":"        if (new_device_owner \u003d\u003d constants.DEVICE_OWNER_ROUTER_HA_INTF and"},{"line_number":102,"context_line":"            new_port[\u0027status\u0027] \u003d\u003d constants.PORT_STATUS_ACTIVE and"},{"line_number":103,"context_line":"            original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027]):"},{"line_number":104,"context_line":"            l3plugin \u003d manager.NeutronManager.get_service_plugins().get("}],"source_content_type":"text/x-python","patch_set":8,"id":"fa7ab95a_890baf8d","line":101,"in_reply_to":"fa7ab95a_2dc0f629","updated":"2016-08-29 14:46:37.000000000","message":"Right, sorry! I got confused by \u0027HA ports\u0027 and \u0027HA router ports\u0027 :)","commit_id":"64239f612699170e65f9a21ff40ba44b075eaab6"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"154affd9eced7131589ffa3652abcae532910c53","unresolved":false,"context_lines":[{"line_number":98,"context_line":""},{"line_number":99,"context_line":"    if new_port and original_port and host:"},{"line_number":100,"context_line":"        new_device_owner \u003d new_port.get(\u0027device_owner\u0027, \u0027\u0027)"},{"line_number":101,"context_line":"        if (new_device_owner \u003d\u003d constants.DEVICE_OWNER_ROUTER_HA_INTF and"},{"line_number":102,"context_line":"            new_port[\u0027status\u0027] \u003d\u003d constants.PORT_STATUS_ACTIVE and"},{"line_number":103,"context_line":"            original_port[\u0027status\u0027] !\u003d new_port[\u0027status\u0027]):"},{"line_number":104,"context_line":"            l3plugin \u003d manager.NeutronManager.get_service_plugins().get("}],"source_content_type":"text/x-python","patch_set":8,"id":"fa7ab95a_2dc0f629","line":101,"in_reply_to":"fa7ab95a_956919c1","updated":"2016-08-29 13:15:48.000000000","message":"Yes. we don\u0027t need to check for HA router interface ports(i.e DEVICE_OWNER_HA_REPLICATED_INT and DEVICE_OWNER_ROUTER_SNAT). We need to notify only HA network ports.","commit_id":"64239f612699170e65f9a21ff40ba44b075eaab6"}],"neutron/services/l3_router/l3_router_plugin.py":[{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"68a724b9cbf87c776536ae91f3a8654db47ea984","unresolved":false,"context_lines":[{"line_number":73,"context_line":"        super(L3RouterPlugin, self).__init__()"},{"line_number":74,"context_line":"        if \u0027dvr\u0027 in self.supported_extension_aliases:"},{"line_number":75,"context_line":"            l3_dvrscheduler_db.subscribe()"},{"line_number":76,"context_line":"        if \u0027l3-ha\u0027 in self.supported_extension_aliases:"},{"line_number":77,"context_line":"            l3_hascheduler_db.subscribe()"},{"line_number":78,"context_line":"        self.agent_notifiers.update("},{"line_number":79,"context_line":"            {n_const.AGENT_TYPE_L3: l3_rpc_agent_api.L3AgentNotifyAPI()})"},{"line_number":80,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"fa7ab95a_e98057f9","line":77,"range":{"start_line":76,"start_character":3,"end_line":77,"end_character":41},"updated":"2016-08-30 19:51:01.000000000","message":"This feature is supported only when l3-ha is enabled.\nSo the unit test, test_update_port_status_notify_port_event_after_update, should be run only when l3-ha is enabled.\n\nhttps://bugs.launchpad.net/networking-odl/+bug/1618601","commit_id":"25f5912cf8f69f18d111bd60a6cc6ee488755ff3"}],"neutron/tests/functional/agent/l3/test_ha_router.py":[{"author":{"_account_id":8873,"name":"Assaf Muller","email":"amuller@redhat.com","username":"amuller"},"change_message_id":"e86b797fb52a82c6b045f26be5dc39b790c88eff","unresolved":false,"context_lines":[{"line_number":319,"context_line":"        common_utils.wait_until_true(lambda: router2.ha_state \u003d\u003d \u0027master\u0027)"},{"line_number":320,"context_line":"        common_utils.wait_until_true(lambda: router1.ha_state \u003d\u003d \u0027backup\u0027)"},{"line_number":321,"context_line":""},{"line_number":322,"context_line":"    def test_ha_port_status_update(self):"},{"line_number":323,"context_line":"        router_info \u003d self.generate_router_info(enable_ha\u003dTrue)"},{"line_number":324,"context_line":"        router_info[l3_constants.HA_INTERFACE_KEY][\u0027status\u0027] \u003d ("},{"line_number":325,"context_line":"            l3_constants.PORT_STATUS_DOWN)"}],"source_content_type":"text/x-python","patch_set":6,"id":"1ac06dbe_731a55c7","line":322,"updated":"2016-08-24 10:35:41.000000000","message":"Why not simplify the test and have only one router on one agent like other HA tests? That allows you to remove the mocking for example.","commit_id":"8e2cc91ea4143267767d08fc47a1e18d395e0252"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"404ba1b6b994453cee928f1aba2cf760387961e6","unresolved":false,"context_lines":[{"line_number":319,"context_line":"        common_utils.wait_until_true(lambda: router2.ha_state \u003d\u003d \u0027master\u0027)"},{"line_number":320,"context_line":"        common_utils.wait_until_true(lambda: router1.ha_state \u003d\u003d \u0027backup\u0027)"},{"line_number":321,"context_line":""},{"line_number":322,"context_line":"    def test_ha_port_status_update(self):"},{"line_number":323,"context_line":"        router_info \u003d self.generate_router_info(enable_ha\u003dTrue)"},{"line_number":324,"context_line":"        router_info[l3_constants.HA_INTERFACE_KEY][\u0027status\u0027] \u003d ("},{"line_number":325,"context_line":"            l3_constants.PORT_STATUS_DOWN)"}],"source_content_type":"text/x-python","patch_set":6,"id":"1ac06dbe_932ef1a2","line":322,"in_reply_to":"1ac06dbe_731a55c7","updated":"2016-08-24 10:40:53.000000000","message":"sure","commit_id":"8e2cc91ea4143267767d08fc47a1e18d395e0252"}],"neutron/tests/unit/plugins/ml2/test_plugin.py":[{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"2a8c73c2f31507ee987129e400ae20c251762db5","unresolved":false,"context_lines":[{"line_number":58,"context_line":"from neutron.plugins.ml2 import managers"},{"line_number":59,"context_line":"from neutron.plugins.ml2 import models"},{"line_number":60,"context_line":"from neutron.plugins.ml2 import plugin as ml2_plugin"},{"line_number":61,"context_line":"from neutron.services.l3_router import l3_router_plugin"},{"line_number":62,"context_line":"from neutron.services.qos import qos_consts"},{"line_number":63,"context_line":"from neutron.tests import base"},{"line_number":64,"context_line":"from neutron.tests.common import helpers"}],"source_content_type":"text/x-python","patch_set":7,"id":"1ac06dbe_253177ed","line":61,"range":{"start_line":61,"start_character":0,"end_line":61,"end_character":55},"updated":"2016-08-25 04:32:11.000000000","message":"ditto","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"2a8c73c2f31507ee987129e400ae20c251762db5","unresolved":false,"context_lines":[{"line_number":711,"context_line":"    def test_update_port_status_notify_port_event_after_update(self):"},{"line_number":712,"context_line":"        ctx \u003d context.get_admin_context()"},{"line_number":713,"context_line":"        plugin \u003d ml2_plugin.Ml2Plugin()"},{"line_number":714,"context_line":"        l3_router_plugin.L3RouterPlugin()"},{"line_number":715,"context_line":"        l3plugin \u003d manager.NeutronManager.get_service_plugins().get("},{"line_number":716,"context_line":"            p_const.L3_ROUTER_NAT)"},{"line_number":717,"context_line":"        host_arg \u003d {portbindings.HOST_ID: HOST}"}],"source_content_type":"text/x-python","patch_set":7,"id":"1ac06dbe_424909d0","line":714,"range":{"start_line":714,"start_character":8,"end_line":714,"end_character":41},"updated":"2016-08-25 04:32:11.000000000","message":"Just a doubt, why do we need here?","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"309386c851056e17d342b0c4c79dacdf06de6a6e","unresolved":false,"context_lines":[{"line_number":711,"context_line":"    def test_update_port_status_notify_port_event_after_update(self):"},{"line_number":712,"context_line":"        ctx \u003d context.get_admin_context()"},{"line_number":713,"context_line":"        plugin \u003d ml2_plugin.Ml2Plugin()"},{"line_number":714,"context_line":"        l3_router_plugin.L3RouterPlugin()"},{"line_number":715,"context_line":"        l3plugin \u003d manager.NeutronManager.get_service_plugins().get("},{"line_number":716,"context_line":"            p_const.L3_ROUTER_NAT)"},{"line_number":717,"context_line":"        host_arg \u003d {portbindings.HOST_ID: HOST}"}],"source_content_type":"text/x-python","patch_set":7,"id":"1ac06dbe_e5c91227","line":714,"range":{"start_line":714,"start_character":8,"end_line":714,"end_character":41},"in_reply_to":"1ac06dbe_424909d0","updated":"2016-08-25 09:16:20.000000000","message":"This is need to add subscription for event. https://review.openstack.org/#/c/357458/7/neutron/services/l3_router/l3_router_plugin.py@76","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":12860,"name":"Dongcan Ye","email":"yedongcan@yeah.net","username":"yedongcan"},"change_message_id":"ec7ae8b7fd9a5a2282a457a6eaa1429d9674dee1","unresolved":false,"context_lines":[{"line_number":711,"context_line":"    def test_update_port_status_notify_port_event_after_update(self):"},{"line_number":712,"context_line":"        ctx \u003d context.get_admin_context()"},{"line_number":713,"context_line":"        plugin \u003d ml2_plugin.Ml2Plugin()"},{"line_number":714,"context_line":"        l3_router_plugin.L3RouterPlugin()"},{"line_number":715,"context_line":"        l3plugin \u003d manager.NeutronManager.get_service_plugins().get("},{"line_number":716,"context_line":"            p_const.L3_ROUTER_NAT)"},{"line_number":717,"context_line":"        host_arg \u003d {portbindings.HOST_ID: HOST}"}],"source_content_type":"text/x-python","patch_set":7,"id":"1ac06dbe_b0073fc8","line":714,"range":{"start_line":714,"start_character":8,"end_line":714,"end_character":41},"in_reply_to":"1ac06dbe_e5c91227","updated":"2016-08-25 14:41:11.000000000","message":"Thanks for clarify.","commit_id":"5d27e6a34a28b2b517703d66a0d6dfe2b613e1d3"},{"author":{"_account_id":8410,"name":"Richard Theis","email":"rtheis@us.ibm.com","username":"rtheis"},"change_message_id":"81044aa095f15dbcbb80f61e125140dcb9ef97d6","unresolved":false,"context_lines":[{"line_number":712,"context_line":""},{"line_number":713,"context_line":"    def test_update_port_status_notify_port_event_after_update(self):"},{"line_number":714,"context_line":"        ctx \u003d context.get_admin_context()"},{"line_number":715,"context_line":"        plugin \u003d ml2_plugin.Ml2Plugin()"},{"line_number":716,"context_line":"        # enable subscription for events"},{"line_number":717,"context_line":"        l3_router_plugin.L3RouterPlugin()"},{"line_number":718,"context_line":"        l3plugin \u003d manager.NeutronManager.get_service_plugins().get("}],"source_content_type":"text/x-python","patch_set":9,"id":"fa7ab95a_5e567f06","line":715,"updated":"2016-08-30 11:34:46.000000000","message":"This is recreating the plugin and breaks the networking-ovn gate job.  Bug https://bugs.launchpad.net/neutron/+bug/1618343 has been opened.","commit_id":"25f5912cf8f69f18d111bd60a6cc6ee488755ff3"},{"author":{"_account_id":10237,"name":"Numan Siddique","email":"nusiddiq@redhat.com","username":"numansiddique"},"change_message_id":"54143a7922e7b195360c01ad8908aa2d57947ecb","unresolved":false,"context_lines":[{"line_number":712,"context_line":""},{"line_number":713,"context_line":"    def test_update_port_status_notify_port_event_after_update(self):"},{"line_number":714,"context_line":"        ctx \u003d context.get_admin_context()"},{"line_number":715,"context_line":"        plugin \u003d ml2_plugin.Ml2Plugin()"},{"line_number":716,"context_line":"        # enable subscription for events"},{"line_number":717,"context_line":"        l3_router_plugin.L3RouterPlugin()"},{"line_number":718,"context_line":"        l3plugin \u003d manager.NeutronManager.get_service_plugins().get("}],"source_content_type":"text/x-python","patch_set":9,"id":"fa7ab95a_db2e21a4","line":715,"updated":"2016-08-30 11:33:46.000000000","message":"This test is causing the networking_ovn unit test to fail [1].\n\nShouldn\u0027t this be\n****\nplugin \u003d manager.NeutronManager.get_plugin()\n*****\n\nWith the above change, this test case is passing.\n\n[1] - http://logs.openstack.org/26/362726/1/check/gate-networking-ovn-python27-ubuntu-xenial/4a77705/testr_results.html.gz","commit_id":"25f5912cf8f69f18d111bd60a6cc6ee488755ff3"},{"author":{"_account_id":7249,"name":"Ann Taraday","email":"akamyshnikova@mirantis.com","username":"AKamyshnikova"},"change_message_id":"87204b5a2065f2389fb3f909ab0d4e7ee6dda9d8","unresolved":false,"context_lines":[{"line_number":712,"context_line":""},{"line_number":713,"context_line":"    def test_update_port_status_notify_port_event_after_update(self):"},{"line_number":714,"context_line":"        ctx \u003d context.get_admin_context()"},{"line_number":715,"context_line":"        plugin \u003d ml2_plugin.Ml2Plugin()"},{"line_number":716,"context_line":"        # enable subscription for events"},{"line_number":717,"context_line":"        l3_router_plugin.L3RouterPlugin()"},{"line_number":718,"context_line":"        l3plugin \u003d manager.NeutronManager.get_service_plugins().get("}],"source_content_type":"text/x-python","patch_set":9,"id":"fa7ab95a_1ee077cc","line":715,"in_reply_to":"fa7ab95a_db2e21a4","updated":"2016-08-30 11:40:43.000000000","message":"Numan\u0027s suggested looks valid.","commit_id":"25f5912cf8f69f18d111bd60a6cc6ee488755ff3"}]}
