)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":704,"name":"Edgar Magana","email":"emagana@gmail.com","username":"emagana"},"change_message_id":"608590f063590e293d2c03d21369162e7f3f5d6f","unresolved":false,"context_lines":[{"line_number":29,"context_line":""},{"line_number":30,"context_line":"This patch fixes the _schedule_router function"},{"line_number":31,"context_line":"and hence avoids the multiple calls to"},{"line_number":32,"context_line":"bind_router."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"This prevents the update_router from failing"},{"line_number":35,"context_line":"and causing the nested rollback for the"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1a930d6b_67904996","line":32,"updated":"2015-01-21 21:58:32.000000000","message":"nit: IMHO lines 12 to 28 should be included in the bug description and not here.","commit_id":"3794b4a83e68041e24b715135f0ccf09a5631178"}],"neutron/scheduler/l3_agent_scheduler.py":[{"author":{"_account_id":8646,"name":"yangxurong","email":"yangxurong@huawei.com","username":"yangxurong"},"change_message_id":"3581af273a35b538551c3d08e2d698404439a4d0","unresolved":false,"context_lines":[{"line_number":249,"context_line":"                # call the unbind_snat_servicenode to unbind the snat service"},{"line_number":250,"context_line":"                # from agent"},{"line_number":251,"context_line":"                plugin.unbind_snat_servicenode(context, router_id)"},{"line_number":252,"context_line":"                return"},{"line_number":253,"context_line":"        candidates \u003d candidates or self.get_candidates("},{"line_number":254,"context_line":"            plugin, context, sync_router)"},{"line_number":255,"context_line":"        if not candidates:"}],"source_content_type":"text/x-python","patch_set":1,"id":"3a961159_7201106a","line":252,"updated":"2014-12-25 02:15:16.000000000","message":"it\u0027s ok in the case of adding interface to router or setting gateway info, but it should not return here when we update legacy router to distributed router because it should not only scheduler snat router but also bind distributed router.","commit_id":"90e49848b836d8448e74ff05bb8b5059845b7ab0"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"880827885d059baf1fcaabb1ffdf6d78c2d43dae","unresolved":false,"context_lines":[{"line_number":249,"context_line":"                # call the unbind_snat_servicenode to unbind the snat service"},{"line_number":250,"context_line":"                # from agent"},{"line_number":251,"context_line":"                plugin.unbind_snat_servicenode(context, router_id)"},{"line_number":252,"context_line":"                return"},{"line_number":253,"context_line":"        candidates \u003d candidates or self.get_candidates("},{"line_number":254,"context_line":"            plugin, context, sync_router)"},{"line_number":255,"context_line":"        if not candidates:"}],"source_content_type":"text/x-python","patch_set":1,"id":"3a961159_37af167f","line":252,"in_reply_to":"3a961159_7201106a","updated":"2015-01-13 20:39:55.000000000","message":"I am not sure if you received my message, when we convert a legacy router to distributed router, still the bind_router will be called within the schedule_snat_router with the same chosen agent after the snat binding occurs.","commit_id":"90e49848b836d8448e74ff05bb8b5059845b7ab0"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"56b13a86ee22486170436a83623321d9e54c0516","unresolved":false,"context_lines":[{"line_number":249,"context_line":"                # call the unbind_snat_servicenode to unbind the snat service"},{"line_number":250,"context_line":"                # from agent"},{"line_number":251,"context_line":"                plugin.unbind_snat_servicenode(context, router_id)"},{"line_number":252,"context_line":"                return"},{"line_number":253,"context_line":"        candidates \u003d candidates or self.get_candidates("},{"line_number":254,"context_line":"            plugin, context, sync_router)"},{"line_number":255,"context_line":"        if not candidates:"}],"source_content_type":"text/x-python","patch_set":1,"id":"3a961159_5146447c","line":252,"in_reply_to":"3a961159_7201106a","updated":"2015-01-06 04:30:17.000000000","message":"The schedule_snat_router function will create both the snat binding and the qrouter binding.\nSo this will work.","commit_id":"90e49848b836d8448e74ff05bb8b5059845b7ab0"},{"author":{"_account_id":10971,"name":"Michael Smith","email":"michael.smith6@hp.com","username":"mrsmith"},"change_message_id":"b9902d8547ef2d42354a130e51867a76613eacb4","unresolved":false,"context_lines":[{"line_number":250,"context_line":"                # from agent"},{"line_number":251,"context_line":"                plugin.unbind_snat_servicenode(context, router_id)"},{"line_number":252,"context_line":"                return"},{"line_number":253,"context_line":"        candidates \u003d candidates or self.get_candidates("},{"line_number":254,"context_line":"            plugin, context, sync_router)"},{"line_number":255,"context_line":"        if not candidates:"},{"line_number":256,"context_line":"            return"}],"source_content_type":"text/x-python","patch_set":1,"id":"3a961159_64e559a7","line":253,"updated":"2014-12-18 17:19:58.000000000","message":"Should we always return the above two cases?","commit_id":"90e49848b836d8448e74ff05bb8b5059845b7ab0"},{"author":{"_account_id":14440,"name":"weibo","email":"weibohome@163.com","username":"weibo"},"change_message_id":"d74250c5619e12b47adfa3431ba7841925b9430b","unresolved":false,"context_lines":[{"line_number":250,"context_line":"                # from agent"},{"line_number":251,"context_line":"                plugin.unbind_snat_servicenode(context, router_id)"},{"line_number":252,"context_line":"                return"},{"line_number":253,"context_line":"        candidates \u003d candidates or self.get_candidates("},{"line_number":254,"context_line":"            plugin, context, sync_router)"},{"line_number":255,"context_line":"        if not candidates:"},{"line_number":256,"context_line":"            return"}],"source_content_type":"text/x-python","patch_set":1,"id":"3a961159_900da6ea","line":253,"in_reply_to":"3a961159_373aa134","updated":"2014-12-24 07:17:11.000000000","message":"hi,Swaminathan Vasudevan,i find that when i update legacy router to distributed router,the qrouter is not schedule if return after schedule_snat_router.","commit_id":"90e49848b836d8448e74ff05bb8b5059845b7ab0"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"096aaee959f60569959dd2fcbf44302d3d2712d8","unresolved":false,"context_lines":[{"line_number":250,"context_line":"                # from agent"},{"line_number":251,"context_line":"                plugin.unbind_snat_servicenode(context, router_id)"},{"line_number":252,"context_line":"                return"},{"line_number":253,"context_line":"        candidates \u003d candidates or self.get_candidates("},{"line_number":254,"context_line":"            plugin, context, sync_router)"},{"line_number":255,"context_line":"        if not candidates:"},{"line_number":256,"context_line":"            return"}],"source_content_type":"text/x-python","patch_set":1,"id":"3a961159_373aa134","line":253,"in_reply_to":"3a961159_64e559a7","updated":"2014-12-18 17:39:41.000000000","message":"Yes at this point it makes sense to return, because if it has a gatway both the qrouter and the snat binding has happened within the \"schedule_snat_router\", and it is safe at this point to return the chosen agent.","commit_id":"90e49848b836d8448e74ff05bb8b5059845b7ab0"},{"author":{"_account_id":14440,"name":"weibo","email":"weibohome@163.com","username":"weibo"},"change_message_id":"4322ae2b8ca3935f737e669d0392cc5adc635361","unresolved":false,"context_lines":[{"line_number":241,"context_line":"            if not snat_bindings and router_gw_exists:"},{"line_number":242,"context_line":"                # If GW exists for DVR routers and no SNAT binding"},{"line_number":243,"context_line":"                # call the schedule_snat_router"},{"line_number":244,"context_line":"                chosen_agent \u003d plugin.schedule_snat_router("},{"line_number":245,"context_line":"                    context, router_id, sync_router)"},{"line_number":246,"context_line":"                return chosen_agent"},{"line_number":247,"context_line":"            if not router_gw_exists and snat_bindings:"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_3b55e0c1","line":244,"updated":"2015-01-16 02:31:12.000000000","message":"hi Swaminathan Vasudevan,when we convert a legacy router to distributed router,other dvr node(not dvr_snat node) should scheduler qrouter.if there return,get_candidates will not run,and compute node will not create qrouter namespace.\ni think there should not return,and should return in next code:\nl3_db.py:\ndef _check_router_needs_rescheduling(self, context, router_id, gw_info):\n        cur_agents \u003d l3_plugin.list_l3_agents_hosting_router(\n            context, router_id)[\u0027agents\u0027]\n        #if router have not binding host, we should not rescheduled this router,so i think there should return.\n        if not cur_agents:\n            return\n        for agent in cur_agents:\n            ext_net_id \u003d agent[\u0027configurations\u0027].get(\n                \u0027gateway_external_network_id\u0027)\n            ext_bridge \u003d agent[\u0027configurations\u0027].get(\n                \u0027external_network_bridge\u0027, \u0027br-ex\u0027)\n            if (ext_net_id \u003d\u003d network_id or\n                    (not ext_net_id and not ext_bridge)):\n                return","commit_id":"290ad9d6376c1aaee9e607c97d4816fbe338cdd8"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"ecdd6ec54b6e40338239e31abbff129b6fd25bb5","unresolved":false,"context_lines":[{"line_number":241,"context_line":"            if not snat_bindings and router_gw_exists:"},{"line_number":242,"context_line":"                # If GW exists for DVR routers and no SNAT binding"},{"line_number":243,"context_line":"                # call the schedule_snat_router"},{"line_number":244,"context_line":"                chosen_agent \u003d plugin.schedule_snat_router("},{"line_number":245,"context_line":"                    context, router_id, sync_router)"},{"line_number":246,"context_line":"                return chosen_agent"},{"line_number":247,"context_line":"            if not router_gw_exists and snat_bindings:"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_5b3b8ce9","line":244,"updated":"2015-01-16 03:06:02.000000000","message":"you could just return here.","commit_id":"290ad9d6376c1aaee9e607c97d4816fbe338cdd8"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"b13c2bf7403a4e28c6cf41534e268ae1e5f7b894","unresolved":false,"context_lines":[{"line_number":241,"context_line":"            if not snat_bindings and router_gw_exists:"},{"line_number":242,"context_line":"                # If GW exists for DVR routers and no SNAT binding"},{"line_number":243,"context_line":"                # call the schedule_snat_router"},{"line_number":244,"context_line":"                chosen_agent \u003d plugin.schedule_snat_router("},{"line_number":245,"context_line":"                    context, router_id, sync_router)"},{"line_number":246,"context_line":"                return chosen_agent"},{"line_number":247,"context_line":"            if not router_gw_exists and snat_bindings:"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a930d6b_f5e6b115","line":244,"in_reply_to":"3a961159_3b55e0c1","updated":"2015-01-21 14:52:59.000000000","message":"Hi Weibo,\nThere is another bug in ml2/plugin.py that does not allow to schedule a router on a \"dvr\" node when a VM is added after the router-interface is added. ( There is bug currently filed for it)\n\nI tested converting a \"legacy\" router to a \"distributed\u0027 router and I don\u0027t see any issue as you have mentioned above.\n\nNOTE: Keep in mind, follow the instructions below to convert a legacy router to a distributed router.\n\nneutron router-update router-legacy --admin_state_up\u003dFalse\nneutron router-update router-legacy --distributed\u003dTrue\nneutron router-update router-legacy --admin_state_up\u003dTrue.\n\nKeep in mind if you don\u0027t follow the above instructions, it may not have the right effect on scheduling.","commit_id":"290ad9d6376c1aaee9e607c97d4816fbe338cdd8"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"b13c2bf7403a4e28c6cf41534e268ae1e5f7b894","unresolved":false,"context_lines":[{"line_number":241,"context_line":"            if not snat_bindings and router_gw_exists:"},{"line_number":242,"context_line":"                # If GW exists for DVR routers and no SNAT binding"},{"line_number":243,"context_line":"                # call the schedule_snat_router"},{"line_number":244,"context_line":"                chosen_agent \u003d plugin.schedule_snat_router("},{"line_number":245,"context_line":"                    context, router_id, sync_router)"},{"line_number":246,"context_line":"                return chosen_agent"},{"line_number":247,"context_line":"            if not router_gw_exists and snat_bindings:"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a930d6b_15e41d0c","line":244,"in_reply_to":"3a961159_5b3b8ce9","updated":"2015-01-21 14:52:59.000000000","message":"Done","commit_id":"290ad9d6376c1aaee9e607c97d4816fbe338cdd8"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"c1f89c9b8bbf372ce767ffbe57aac5489a4b8330","unresolved":false,"context_lines":[{"line_number":241,"context_line":"            if not snat_bindings and router_gw_exists:"},{"line_number":242,"context_line":"                # If GW exists for DVR routers and no SNAT binding"},{"line_number":243,"context_line":"                # call the schedule_snat_router"},{"line_number":244,"context_line":"                chosen_agent \u003d plugin.schedule_snat_router("},{"line_number":245,"context_line":"                    context, router_id, sync_router)"},{"line_number":246,"context_line":"                return chosen_agent"},{"line_number":247,"context_line":"            if not router_gw_exists and snat_bindings:"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_92fa1fb8","line":244,"in_reply_to":"3a961159_5b3b8ce9","updated":"2015-01-16 17:08:12.000000000","message":"will address it in the next patch.","commit_id":"290ad9d6376c1aaee9e607c97d4816fbe338cdd8"}],"neutron/tests/unit/test_l3_schedulers.py":[{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"ecdd6ec54b6e40338239e31abbff129b6fd25bb5","unresolved":false,"context_lines":[{"line_number":494,"context_line":"        }"},{"line_number":495,"context_line":"        plugin.get_router.return_value \u003d sync_router"},{"line_number":496,"context_line":"        with mock.patch.object("},{"line_number":497,"context_line":"            plugin, \u0027get_snat_bindings\u0027, return_value\u003dFalse):"},{"line_number":498,"context_line":"                scheduler._schedule_router("},{"line_number":499,"context_line":"                    plugin, self.adminContext, \u0027foo_router_id\u0027, None)"},{"line_number":500,"context_line":"        expected_calls \u003d ["}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_db4f7c8a","line":497,"updated":"2015-01-16 03:06:02.000000000","message":"no action for this patch, but a follow-up action for you to consider: I would love if we broke this file of test cases in DVR and non-DVR, it would help us isolate the changes better.","commit_id":"290ad9d6376c1aaee9e607c97d4816fbe338cdd8"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"b13c2bf7403a4e28c6cf41534e268ae1e5f7b894","unresolved":false,"context_lines":[{"line_number":494,"context_line":"        }"},{"line_number":495,"context_line":"        plugin.get_router.return_value \u003d sync_router"},{"line_number":496,"context_line":"        with mock.patch.object("},{"line_number":497,"context_line":"            plugin, \u0027get_snat_bindings\u0027, return_value\u003dFalse):"},{"line_number":498,"context_line":"                scheduler._schedule_router("},{"line_number":499,"context_line":"                    plugin, self.adminContext, \u0027foo_router_id\u0027, None)"},{"line_number":500,"context_line":"        expected_calls \u003d ["}],"source_content_type":"text/x-python","patch_set":2,"id":"1a930d6b_55c5c559","line":497,"in_reply_to":"3a961159_db4f7c8a","updated":"2015-01-21 14:52:59.000000000","message":"Will consider it as a follow on patch.","commit_id":"290ad9d6376c1aaee9e607c97d4816fbe338cdd8"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"ecdd6ec54b6e40338239e31abbff129b6fd25bb5","unresolved":false,"context_lines":[{"line_number":1027,"context_line":"        self.assertTrue(mock_bind_snat.called)"},{"line_number":1028,"context_line":"        self.assertFalse(mock_bind_dvr.called)"},{"line_number":1029,"context_line":""},{"line_number":1030,"context_line":"    def test_schedule_snat_router_return_value(self):"},{"line_number":1031,"context_line":"        agent, router \u003d self._prepare_schedule_snat_tests()"},{"line_number":1032,"context_line":"        with contextlib.nested("},{"line_number":1033,"context_line":"            mock.patch.object(self.dut, \u0027get_l3_agents\u0027),"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_fb18b885","line":1030,"updated":"2015-01-16 03:06:02.000000000","message":"I think that testing this at unit level it won\u0027t give us the appropriate level of qa. I wonder if we a functional test would be more effective. Have you given it any thoughts?","commit_id":"290ad9d6376c1aaee9e607c97d4816fbe338cdd8"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"c1f89c9b8bbf372ce767ffbe57aac5489a4b8330","unresolved":false,"context_lines":[{"line_number":1027,"context_line":"        self.assertTrue(mock_bind_snat.called)"},{"line_number":1028,"context_line":"        self.assertFalse(mock_bind_dvr.called)"},{"line_number":1029,"context_line":""},{"line_number":1030,"context_line":"    def test_schedule_snat_router_return_value(self):"},{"line_number":1031,"context_line":"        agent, router \u003d self._prepare_schedule_snat_tests()"},{"line_number":1032,"context_line":"        with contextlib.nested("},{"line_number":1033,"context_line":"            mock.patch.object(self.dut, \u0027get_l3_agents\u0027),"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_f20b63d2","line":1030,"in_reply_to":"3a961159_fb18b885","updated":"2015-01-16 17:08:12.000000000","message":"Yes we are working on the functional test for the Mutliple external networks.","commit_id":"290ad9d6376c1aaee9e607c97d4816fbe338cdd8"}]}
