)]}'
{"neutron/db/l3_dvr_db.py":[{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"5903b492c8b80496229f7463965a6821aabb7a07","unresolved":false,"context_lines":[{"line_number":182,"context_line":"            l3_db.RouterPort.port_type.in_(l3_const.ROUTER_INTERFACE_OWNERS)"},{"line_number":183,"context_line":"        )"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"    def _check_previous_host_and_current_host("},{"line_number":186,"context_line":"        self, context, cur_port_id, prev_port_id):"},{"line_number":187,"context_line":"        cur_vm_hostid \u003d self._get_vm_port_hostid("},{"line_number":188,"context_line":"            context, cur_port_id)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_c8c4f193","line":185,"updated":"2015-05-06 11:53:06.000000000","message":"it doesn\u0027t check, it just returns","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"ed8696e87212dcd56cb33a5ff26e2ffcc41022c6","unresolved":false,"context_lines":[{"line_number":182,"context_line":"            l3_db.RouterPort.port_type.in_(l3_const.ROUTER_INTERFACE_OWNERS)"},{"line_number":183,"context_line":"        )"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"    def _check_previous_host_and_current_host("},{"line_number":186,"context_line":"        self, context, cur_port_id, prev_port_id):"},{"line_number":187,"context_line":"        cur_vm_hostid \u003d self._get_vm_port_hostid("},{"line_number":188,"context_line":"            context, cur_port_id)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_557df11a","line":185,"in_reply_to":"1aca2d91_c8c4f193","updated":"2015-05-07 06:27:02.000000000","message":"Done","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"5903b492c8b80496229f7463965a6821aabb7a07","unresolved":false,"context_lines":[{"line_number":183,"context_line":"        )"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"    def _check_previous_host_and_current_host("},{"line_number":186,"context_line":"        self, context, cur_port_id, prev_port_id):"},{"line_number":187,"context_line":"        cur_vm_hostid \u003d self._get_vm_port_hostid("},{"line_number":188,"context_line":"            context, cur_port_id)"},{"line_number":189,"context_line":"        prev_vm_hostid \u003d self._get_vm_port_hostid("}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_68527ddf","line":186,"updated":"2015-05-06 11:53:06.000000000","message":"please fix indent so parameters does not look like the body of method","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"ed8696e87212dcd56cb33a5ff26e2ffcc41022c6","unresolved":false,"context_lines":[{"line_number":183,"context_line":"        )"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"    def _check_previous_host_and_current_host("},{"line_number":186,"context_line":"        self, context, cur_port_id, prev_port_id):"},{"line_number":187,"context_line":"        cur_vm_hostid \u003d self._get_vm_port_hostid("},{"line_number":188,"context_line":"            context, cur_port_id)"},{"line_number":189,"context_line":"        prev_vm_hostid \u003d self._get_vm_port_hostid("}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_357a7525","line":186,"in_reply_to":"1aca2d91_68527ddf","updated":"2015-05-07 06:27:02.000000000","message":"Done","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"5903b492c8b80496229f7463965a6821aabb7a07","unresolved":false,"context_lines":[{"line_number":192,"context_line":""},{"line_number":193,"context_line":"    def _fip_disassociate_calls_delete_agent_gw_port("},{"line_number":194,"context_line":"        self, context, floatingip_db):"},{"line_number":195,"context_line":"        admin_ctx \u003d context.elevated()"},{"line_number":196,"context_line":"        router_dict \u003d self.get_router("},{"line_number":197,"context_line":"            admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":198,"context_line":"        # Check if distributed router and then delete the"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_286365b3","line":195,"updated":"2015-05-06 11:53:06.000000000","message":"ditto","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"ed8696e87212dcd56cb33a5ff26e2ffcc41022c6","unresolved":false,"context_lines":[{"line_number":192,"context_line":""},{"line_number":193,"context_line":"    def _fip_disassociate_calls_delete_agent_gw_port("},{"line_number":194,"context_line":"        self, context, floatingip_db):"},{"line_number":195,"context_line":"        admin_ctx \u003d context.elevated()"},{"line_number":196,"context_line":"        router_dict \u003d self.get_router("},{"line_number":197,"context_line":"            admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":198,"context_line":"        # Check if distributed router and then delete the"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_f573dd4b","line":195,"in_reply_to":"1aca2d91_286365b3","updated":"2015-05-07 06:27:02.000000000","message":"Done","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":13770,"name":"Adolfo Duarte","email":"adduarte@redhat.com","username":"adolfoduarte"},"change_message_id":"dedf71c9ca9d407229890b29cdc947a12b09c3c6","unresolved":false,"context_lines":[{"line_number":230,"context_line":"                    self.create_fip_agent_gw_port_if_not_exists("},{"line_number":231,"context_line":"                        admin_ctx, external_port[\u0027network_id\u0027],"},{"line_number":232,"context_line":"                        vm_hostid))"},{"line_number":233,"context_line":"                LOG.debug(\"FIP Agent gateway port: %s\", fip_agent_port)"},{"line_number":234,"context_line":""},{"line_number":235,"context_line":"    def _update_fip_assoc(self, context, fip, floatingip_db, external_port):"},{"line_number":236,"context_line":"        \"\"\"Override to create and delete floating agent gw port for DVR."}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_117a0025","line":233,"updated":"2015-05-06 18:15:08.000000000","message":"I think you mean this line to be\nLOG.debug(\"FIP Agent gateway port: %s\"%fip_agent_port) \nalso, unless fip_agent_port has a __str___  method it might print the object number. \nPerhaps this then: \nLOG.debug(\"FIP Agent gateway port: %s\"%str(fip_agent_port))","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"ed8696e87212dcd56cb33a5ff26e2ffcc41022c6","unresolved":false,"context_lines":[{"line_number":230,"context_line":"                    self.create_fip_agent_gw_port_if_not_exists("},{"line_number":231,"context_line":"                        admin_ctx, external_port[\u0027network_id\u0027],"},{"line_number":232,"context_line":"                        vm_hostid))"},{"line_number":233,"context_line":"                LOG.debug(\"FIP Agent gateway port: %s\", fip_agent_port)"},{"line_number":234,"context_line":""},{"line_number":235,"context_line":"    def _update_fip_assoc(self, context, fip, floatingip_db, external_port):"},{"line_number":236,"context_line":"        \"\"\"Override to create and delete floating agent gw port for DVR."}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_15dc1911","line":233,"in_reply_to":"1aca2d91_117a0025","updated":"2015-05-07 06:27:02.000000000","message":"I think it is fine this way and it would work.","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"5903b492c8b80496229f7463965a6821aabb7a07","unresolved":false,"context_lines":[{"line_number":242,"context_line":"        \"\"\""},{"line_number":243,"context_line":"        fip_port \u003d fip.get(\u0027port_id\u0027)"},{"line_number":244,"context_line":"        unused_fip_agent_gw_port \u003d ("},{"line_number":245,"context_line":"            fip_port is None and floatingip_db[\u0027fixed_port_id\u0027])"},{"line_number":246,"context_line":"        if unused_fip_agent_gw_port and floatingip_db.get(\u0027router_id\u0027):"},{"line_number":247,"context_line":"            self._fip_disassociate_calls_delete_agent_gw_port("},{"line_number":248,"context_line":"                context, floatingip_db)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_0e355145","line":245,"updated":"2015-05-06 11:53:06.000000000","message":"It seems changing this to \n floatingip_db[\u0027fixed_port_id\u0027] and fip_port !\u003d floatingip_db[\u0027fixed_port_id\u0027]\n\nshould be enough for fixing the bug.\n\nCan you please separate this to two patches so it\u0027s clear where is fix and where is refactoring?","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"ed8696e87212dcd56cb33a5ff26e2ffcc41022c6","unresolved":false,"context_lines":[{"line_number":242,"context_line":"        \"\"\""},{"line_number":243,"context_line":"        fip_port \u003d fip.get(\u0027port_id\u0027)"},{"line_number":244,"context_line":"        unused_fip_agent_gw_port \u003d ("},{"line_number":245,"context_line":"            fip_port is None and floatingip_db[\u0027fixed_port_id\u0027])"},{"line_number":246,"context_line":"        if unused_fip_agent_gw_port and floatingip_db.get(\u0027router_id\u0027):"},{"line_number":247,"context_line":"            self._fip_disassociate_calls_delete_agent_gw_port("},{"line_number":248,"context_line":"                context, floatingip_db)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_75ec6dc7","line":245,"in_reply_to":"1aca2d91_0e355145","updated":"2015-05-07 06:27:02.000000000","message":"the condition above might not be the right option. I have improved the check in my next patch.\nAlso I found that this current fix kind of increases the the size of the _update_fip_assoc function and that is the reason I need to refactor it.","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"9e31996cf7ff2627a363b613125297b897464d58","unresolved":false,"context_lines":[{"line_number":242,"context_line":"        \"\"\""},{"line_number":243,"context_line":"        fip_port \u003d fip.get(\u0027port_id\u0027)"},{"line_number":244,"context_line":"        unused_fip_agent_gw_port \u003d ("},{"line_number":245,"context_line":"            fip_port is None and floatingip_db[\u0027fixed_port_id\u0027])"},{"line_number":246,"context_line":"        if unused_fip_agent_gw_port and floatingip_db.get(\u0027router_id\u0027):"},{"line_number":247,"context_line":"            self._fip_disassociate_calls_delete_agent_gw_port("},{"line_number":248,"context_line":"                context, floatingip_db)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_fefe156a","line":245,"in_reply_to":"1aca2d91_75ec6dc7","updated":"2015-05-07 10:22:39.000000000","message":"indeed, we need to check host change, not just fixed_port change","commit_id":"ac66e59a892d28a146ac0b485c11f832c67c9588"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"261bc5e6d8a1a5430902d50dda18a0391dbb52be","unresolved":false,"context_lines":[{"line_number":243,"context_line":"        a floatingIP association changes from a port on one host to"},{"line_number":244,"context_line":"        another."},{"line_number":245,"context_line":"        \"\"\""},{"line_number":246,"context_line":"        fip_port \u003d fip.get(\u0027port_id\u0027)"},{"line_number":247,"context_line":"        unused_fip_agent_gw_port \u003d ("},{"line_number":248,"context_line":"            fip_port is None and floatingip_db[\u0027fixed_port_id\u0027])"},{"line_number":249,"context_line":"        if unused_fip_agent_gw_port and floatingip_db.get(\u0027router_id\u0027):"}],"source_content_type":"text/x-python","patch_set":2,"id":"1aca2d91_c4738c7f","line":246,"updated":"2015-05-07 13:06:45.000000000","message":"With the proposed refactoring this is even harder to read and understand. Consider changing to smth like:\n\ndef _update_fip_assoc(...)\n if not floatingip_db.get(\u0027router_id\u0027):\n   return\n\n admin_ctx \u003d context.elevated()\n router \u003d self.get_router(admin_ctx, floatingip_db[\u0027router_id\u0027])\n if not router.get(\u0027distributed\u0027):\n   return\n \n cur_port_id \u003d floatingip_db[\u0027fixed_port_id\u0027]\n cur_host \u003d self._get_vm_port_hostid(context, cur_port_id) if cur_port_id\n                  else None\n new_port_id \u003d fip.get(\u0027port_id\u0027)\n new_host \u003d self._get_vm_port_hostid(context, new_port_id) if new_port_id\n                   else None\n\n if cur_host and cur_host !\u003d new_host:\n   self._clear_unused_fip_agent_gw_port(...)\n \n super(L3_NAT_with_dvr_db_mixin, self)._update_fip_assoc(...)\n\n if new_host:\n   self.create_fip_agent_gw_port_if_not_exists(..)\n\nNo additional  methods needed! :)","commit_id":"1a7120370d6c22b2417d4a4d84f1b5e2edb66348"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"261bc5e6d8a1a5430902d50dda18a0391dbb52be","unresolved":false,"context_lines":[{"line_number":260,"context_line":"            context, fip, floatingip_db, external_port)"},{"line_number":261,"context_line":"        associate_fip \u003d fip_port and floatingip_db[\u0027id\u0027]"},{"line_number":262,"context_line":"        if associate_fip and floatingip_db.get(\u0027router_id\u0027):"},{"line_number":263,"context_line":"            self._fip_associate_calls_create_agent_gw_port("},{"line_number":264,"context_line":"                context, fip_port, floatingip_db, external_port)"},{"line_number":265,"context_line":""},{"line_number":266,"context_line":"    def _clear_unused_fip_agent_gw_port("}],"source_content_type":"text/x-python","patch_set":2,"id":"1aca2d91_816d869a","line":263,"updated":"2015-05-07 13:06:45.000000000","message":"this refactoring is not related to the bug!","commit_id":"1a7120370d6c22b2417d4a4d84f1b5e2edb66348"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"ca74b4797ddfa1ae411cd8e4ccdf8fe9a55f187d","unresolved":false,"context_lines":[{"line_number":197,"context_line":"    def _fip_associate_create_agent_gw_port("},{"line_number":198,"context_line":"            self, context, fip_port, floatingip_db, external_port):"},{"line_number":199,"context_line":"        \"\"\"Creates floating agent gw port for DVR.\"\"\""},{"line_number":200,"context_line":"        admin_ctx \u003d context.elevated()"},{"line_number":201,"context_line":"        router_dict \u003d self.get_router("},{"line_number":202,"context_line":"            admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":203,"context_line":"        # Check if distributed router and then create the"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a0c5dc1_665beb55","line":200,"updated":"2015-05-12 08:55:11.000000000","message":"200 - 205 duplicates 188 - 193. Can you please comment what you think on my comment in PS2? I think we can get bug fix and refactoring with one rather simple change.","commit_id":"dadeb7b4d3123916b8e3bf40463be2e94c5d9c10"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"bc347cc755836b7a3e1bc1242a85f087712cebca","unresolved":false,"context_lines":[{"line_number":197,"context_line":"    def _fip_associate_create_agent_gw_port("},{"line_number":198,"context_line":"            self, context, fip_port, floatingip_db, external_port):"},{"line_number":199,"context_line":"        \"\"\"Creates floating agent gw port for DVR.\"\"\""},{"line_number":200,"context_line":"        admin_ctx \u003d context.elevated()"},{"line_number":201,"context_line":"        router_dict \u003d self.get_router("},{"line_number":202,"context_line":"            admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":203,"context_line":"        # Check if distributed router and then create the"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a0c5dc1_ad3bb2d0","line":200,"in_reply_to":"9a0c5dc1_2625dcaa","updated":"2015-05-13 18:08:16.000000000","message":"Hi Oleg, I tried to incorporate your recommended changes, but it does not work or address the issue as expected.\n\nThe duplication of code for getting the router and elevating the admin context in this function is unpreventable. But at any point of time there is going to be only one db call to look for the router. \n\nThe reason is floatingip_db.get(\u0027router_id\u0027) will be valid only for \"disassociate/migrate\" case and will not be true for \"associate\".\n\nThe floatingip_db.get(\u0027router_id\u0027) will be populated only after we do a call to the \"super class\".\n\nSo there is a need for these two lines of code to be repeated under each context. This was how the code was before.\n\nIn my latest patch I have incorported some of your review comments and have not refactored the function much. \n\nI just wanted to split the \"get_previous_and_current_host\", to be more clean.\n\nHope this helps.","commit_id":"dadeb7b4d3123916b8e3bf40463be2e94c5d9c10"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"6afebc5d234da66a9af9e0e50c71e1294b62eccb","unresolved":false,"context_lines":[{"line_number":197,"context_line":"    def _fip_associate_create_agent_gw_port("},{"line_number":198,"context_line":"            self, context, fip_port, floatingip_db, external_port):"},{"line_number":199,"context_line":"        \"\"\"Creates floating agent gw port for DVR.\"\"\""},{"line_number":200,"context_line":"        admin_ctx \u003d context.elevated()"},{"line_number":201,"context_line":"        router_dict \u003d self.get_router("},{"line_number":202,"context_line":"            admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":203,"context_line":"        # Check if distributed router and then create the"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a0c5dc1_2625dcaa","line":200,"in_reply_to":"9a0c5dc1_637e26e6","updated":"2015-05-12 16:02:02.000000000","message":"Can you please comment what you think on my comment in PS2?","commit_id":"dadeb7b4d3123916b8e3bf40463be2e94c5d9c10"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"b3535f2612490f8efd7947a793c8f3b906d87447","unresolved":false,"context_lines":[{"line_number":197,"context_line":"    def _fip_associate_create_agent_gw_port("},{"line_number":198,"context_line":"            self, context, fip_port, floatingip_db, external_port):"},{"line_number":199,"context_line":"        \"\"\"Creates floating agent gw port for DVR.\"\"\""},{"line_number":200,"context_line":"        admin_ctx \u003d context.elevated()"},{"line_number":201,"context_line":"        router_dict \u003d self.get_router("},{"line_number":202,"context_line":"            admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":203,"context_line":"        # Check if distributed router and then create the"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a0c5dc1_637e26e6","line":200,"in_reply_to":"9a0c5dc1_665beb55","updated":"2015-05-12 15:54:15.000000000","message":"Yes I will try to move the common code out of the these functions.\nWill update a patch with the fix.","commit_id":"dadeb7b4d3123916b8e3bf40463be2e94c5d9c10"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"ed7051983e84e2823f38dc5e2d9cd845d19e9454","unresolved":false,"context_lines":[{"line_number":210,"context_line":"        unused_fip_agent_gw_port \u003d ("},{"line_number":211,"context_line":"            new_port_id is None and floatingip_db[\u0027fixed_port_id\u0027])"},{"line_number":212,"context_line":""},{"line_number":213,"context_line":"        if floatingip_db.get(\u0027router_id\u0027):"},{"line_number":214,"context_line":"            admin_ctx \u003d context.elevated()"},{"line_number":215,"context_line":"            router_dict \u003d self.get_router("},{"line_number":216,"context_line":"                admin_ctx, floatingip_db[\u0027router_id\u0027])"}],"source_content_type":"text/x-python","patch_set":7,"id":"9a0c5dc1_4961dd38","line":213,"updated":"2015-05-13 12:18:51.000000000","message":"It seems like the logic from here on has some redundancy and could be cleaned up/reorganized.\n\nFor example, L225 occurs when have router id, is distributed, and no new port id. L230 does same action when hosts don\u0027t match and have router id and distributed.  Maybe a flag could be set to indicate if unused port or host change and then do the clear if that flag and router id/distributed is set (in one if clause).\n\nAlso, context is elevated here, but isn\u0027t it done again on L235-237 (with a narrower check of new host/port)? Couldn\u0027t L234 just test for new host/port and distributed?","commit_id":"71599c6318c414a1ba50c96f3991f9820c32c93b"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"697fa1e699f6b89a121900075a294462e724392b","unresolved":false,"context_lines":[{"line_number":210,"context_line":"        unused_fip_agent_gw_port \u003d ("},{"line_number":211,"context_line":"            new_port_id is None and floatingip_db[\u0027fixed_port_id\u0027])"},{"line_number":212,"context_line":""},{"line_number":213,"context_line":"        if floatingip_db.get(\u0027router_id\u0027):"},{"line_number":214,"context_line":"            admin_ctx \u003d context.elevated()"},{"line_number":215,"context_line":"            router_dict \u003d self.get_router("},{"line_number":216,"context_line":"                admin_ctx, floatingip_db[\u0027router_id\u0027])"}],"source_content_type":"text/x-python","patch_set":7,"id":"9a0c5dc1_f64a9c82","line":213,"in_reply_to":"9a0c5dc1_4961dd38","updated":"2015-05-13 17:33:13.000000000","message":"I will try to address your review comments.\n\nBut here in this case I don\u0027t think there is a good way to reduce the duplication of code with respect to \"self.get_router\" and elevating the context.\n\nThe reason is floatingip_db.get(\u0027router_id\u0027) exists only for \"fip\" disassociationa and not for association case. \nIn the case of association the \"floatingip_db.get(\"router_id\") will be populated only after the \"super\" class function _update_fip_assoc is called.\n\nPlease let me know your thoughts.","commit_id":"71599c6318c414a1ba50c96f3991f9820c32c93b"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"b9d97d1f1a043845ab64b45deb70319aed886990","unresolved":false,"context_lines":[{"line_number":223,"context_line":"                    admin_ctx, floatingip_db, host\u003dcur_port_host)"},{"line_number":224,"context_line":"        super(L3_NAT_with_dvr_db_mixin, self)._update_fip_assoc("},{"line_number":225,"context_line":"            context, fip, floatingip_db, external_port)"},{"line_number":226,"context_line":"        if new_port_host and new_port_id and floatingip_db.get(\u0027router_id\u0027):"},{"line_number":227,"context_line":"            admin_ctx \u003d context.elevated()"},{"line_number":228,"context_line":"            router_dict \u003d self.get_router("},{"line_number":229,"context_line":"                admin_ctx, floatingip_db[\u0027router_id\u0027])"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a016987_08276365","line":226,"updated":"2015-05-15 14:28:22.000000000","message":"no need to check both new_port_host and new_port_id, new_port_host should be enough. Also seems nothing should be done if new_port_host \u003d\u003d cur_port_host","commit_id":"70d0159889973f951e9599204bebde39f338e685"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"f3f121d6c9d270ef2dcdc2928602a874285907e6","unresolved":false,"context_lines":[{"line_number":223,"context_line":"                    admin_ctx, floatingip_db, host\u003dcur_port_host)"},{"line_number":224,"context_line":"        super(L3_NAT_with_dvr_db_mixin, self)._update_fip_assoc("},{"line_number":225,"context_line":"            context, fip, floatingip_db, external_port)"},{"line_number":226,"context_line":"        if new_port_host and new_port_id and floatingip_db.get(\u0027router_id\u0027):"},{"line_number":227,"context_line":"            admin_ctx \u003d context.elevated()"},{"line_number":228,"context_line":"            router_dict \u003d self.get_router("},{"line_number":229,"context_line":"                admin_ctx, floatingip_db[\u0027router_id\u0027])"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a016987_baf40e87","line":226,"in_reply_to":"7a016987_08276365","updated":"2015-05-15 17:54:25.000000000","message":"Oleg yes I will remove the \"new_port_host\".\n\nI don\u0027t see any valid case where you will get an association twice with the same host. The client should already catch it saying the floatingip is already associated with it.\nSo the new_port_host \u003d\u003d cur_port_host will not happen. That is my understanding? am i missing something.","commit_id":"70d0159889973f951e9599204bebde39f338e685"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"386c7d4696cbf442b5646c1ddd3356aa2d876000","unresolved":false,"context_lines":[{"line_number":223,"context_line":"                    admin_ctx, floatingip_db, host\u003dcur_port_host)"},{"line_number":224,"context_line":"        super(L3_NAT_with_dvr_db_mixin, self)._update_fip_assoc("},{"line_number":225,"context_line":"            context, fip, floatingip_db, external_port)"},{"line_number":226,"context_line":"        if new_port_host and new_port_id and floatingip_db.get(\u0027router_id\u0027):"},{"line_number":227,"context_line":"            admin_ctx \u003d context.elevated()"},{"line_number":228,"context_line":"            router_dict \u003d self.get_router("},{"line_number":229,"context_line":"                admin_ctx, floatingip_db[\u0027router_id\u0027])"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a016987_a25aa028","line":226,"in_reply_to":"7a016987_baf40e87","updated":"2015-05-15 19:17:59.000000000","message":"Sorry I was too quick to respond, yes there might be a case where you can assign the same floatingip on host A to a different private id on the same host A without disassociating.\nnew_port_host \u003d\u003d cur_port_host is a valid case","commit_id":"70d0159889973f951e9599204bebde39f338e685"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"30955faa7cd4b2da708096517b7f17491e88863b","unresolved":false,"context_lines":[{"line_number":213,"context_line":"            # Check if distributed router and then delete the"},{"line_number":214,"context_line":"            # FloatingIP agent gateway port"},{"line_number":215,"context_line":"            admin_ctx \u003d context.elevated()"},{"line_number":216,"context_line":"            router_dict \u003d self.get_router("},{"line_number":217,"context_line":"                admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":218,"context_line":"            if router_dict.get(\u0027distributed\u0027):"},{"line_number":219,"context_line":"                # If disassociate or fip migrate go ahead and remove the"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_8e8bf167","line":216,"updated":"2015-05-20 22:32:39.000000000","message":"what about using a more lightweight self._get_router() and is_distributed_router() helper for optimization and consistency? not related to current fix, just something that may be improved in some future patch","commit_id":"002090c9f8e6473cde838ea274f4a186b8270edd"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"fac5ec817710dd24cf45f7f4ada590d138da5a0e","unresolved":false,"context_lines":[{"line_number":213,"context_line":"            # Check if distributed router and then delete the"},{"line_number":214,"context_line":"            # FloatingIP agent gateway port"},{"line_number":215,"context_line":"            admin_ctx \u003d context.elevated()"},{"line_number":216,"context_line":"            router_dict \u003d self.get_router("},{"line_number":217,"context_line":"                admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":218,"context_line":"            if router_dict.get(\u0027distributed\u0027):"},{"line_number":219,"context_line":"                # If disassociate or fip migrate go ahead and remove the"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_1e8901cb","line":216,"in_reply_to":"7a016987_8e8bf167","updated":"2015-05-26 17:24:54.000000000","message":"sure will add it later.","commit_id":"002090c9f8e6473cde838ea274f4a186b8270edd"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"30955faa7cd4b2da708096517b7f17491e88863b","unresolved":false,"context_lines":[{"line_number":227,"context_line":"            return"},{"line_number":228,"context_line":"        if new_port_host and floatingip_db.get(\u0027router_id\u0027):"},{"line_number":229,"context_line":"            admin_ctx \u003d context.elevated()"},{"line_number":230,"context_line":"            router_dict \u003d self.get_router("},{"line_number":231,"context_line":"                admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":232,"context_line":"            if router_dict.get(\u0027distributed\u0027):"},{"line_number":233,"context_line":"                # FIXME (Swami): This FIP Agent Gateway port should be"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_4ef059fe","line":230,"updated":"2015-05-20 22:32:39.000000000","message":"ditto","commit_id":"002090c9f8e6473cde838ea274f4a186b8270edd"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"fac5ec817710dd24cf45f7f4ada590d138da5a0e","unresolved":false,"context_lines":[{"line_number":227,"context_line":"            return"},{"line_number":228,"context_line":"        if new_port_host and floatingip_db.get(\u0027router_id\u0027):"},{"line_number":229,"context_line":"            admin_ctx \u003d context.elevated()"},{"line_number":230,"context_line":"            router_dict \u003d self.get_router("},{"line_number":231,"context_line":"                admin_ctx, floatingip_db[\u0027router_id\u0027])"},{"line_number":232,"context_line":"            if router_dict.get(\u0027distributed\u0027):"},{"line_number":233,"context_line":"                # FIXME (Swami): This FIP Agent Gateway port should be"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_de9249f6","line":230,"in_reply_to":"7a016987_4ef059fe","updated":"2015-05-26 17:24:54.000000000","message":"not with this patch, but will add it as a separate patch.","commit_id":"002090c9f8e6473cde838ea274f4a186b8270edd"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"7456a88465c4e98e7a5a4880a5c736394ff06966","unresolved":false,"context_lines":[{"line_number":183,"context_line":"            l3_db.RouterPort.port_type.in_(l3_const.ROUTER_INTERFACE_OWNERS)"},{"line_number":184,"context_line":"        )"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"    def _get_fip_previous_host_and_current_host("},{"line_number":187,"context_line":"            self, context, new_port_id, cur_port_id):"},{"line_number":188,"context_line":"        cur_port_host \u003d ("},{"line_number":189,"context_line":"            self._get_vm_port_hostid("}],"source_content_type":"text/x-python","patch_set":11,"id":"3afb71cf_187f07e1","line":186,"updated":"2015-06-11 08:34:32.000000000","message":"I\u0027d like to understand the reasoning for making a helper method a bit better: this is used in one place only so we have no benifit in LoC , I can hardly imagine where else this might be useful . _fip_ is also confusing here as it just returns hosts for two passed ports.\nAs I already mentioned in my earlier comments DVR code is already quite complex and hard to catch up/maintain. That\u0027s the reason for my concern.","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"2cd3e358013b7fda4bbda777dfb2bec8f5b15275","unresolved":false,"context_lines":[{"line_number":183,"context_line":"            l3_db.RouterPort.port_type.in_(l3_const.ROUTER_INTERFACE_OWNERS)"},{"line_number":184,"context_line":"        )"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"    def _get_fip_previous_host_and_current_host("},{"line_number":187,"context_line":"            self, context, new_port_id, cur_port_id):"},{"line_number":188,"context_line":"        cur_port_host \u003d ("},{"line_number":189,"context_line":"            self._get_vm_port_hostid("}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_e355d3c1","line":186,"in_reply_to":"3afb71cf_187f07e1","updated":"2015-06-17 20:30:52.000000000","message":"This makes the code more clean and the functionality specific to what it is doing.\nI have been adviced by the community cores to split the function if it goes beyond certain number of lines if possible.\n\nthis would help to write better unit test.\n\nYou asked about why using \"_fip_\" in this function. Even though this function just returns the host, it validates the host binding of the floating ip.\n\nYes I agree with you that DVR code is quite complex to understand, but right now we are working on making it look simple, that\u0027s why we are trying to break down the function based on its functionality.","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"be039acb574cc4e70ed900e13fe54827a53fe159","unresolved":false,"context_lines":[{"line_number":183,"context_line":"            l3_db.RouterPort.port_type.in_(l3_const.ROUTER_INTERFACE_OWNERS)"},{"line_number":184,"context_line":"        )"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"    def _get_fip_previous_host_and_current_host("},{"line_number":187,"context_line":"            self, context, new_port_id, cur_port_id):"},{"line_number":188,"context_line":"        cur_port_host \u003d ("},{"line_number":189,"context_line":"            self._get_vm_port_hostid("}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_ed2f4786","line":186,"in_reply_to":"fa32b979_e355d3c1","updated":"2015-06-23 08:26:30.000000000","message":"\u003e\u003e You asked about why using \"_fip_\" in this function. Even though this function just returns the host, it validates the host binding of the floating ip\n\nI\u0027m not seeing any validation done in here, the func just returns hosts of two passed ports, isn\u0027t it? It has nothing to do with floating ips","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"47e202192e8ca63ed1987f0fe9fe51c2173f9b07","unresolved":false,"context_lines":[{"line_number":255,"context_line":"            host \u003d self._get_vm_port_hostid("},{"line_number":256,"context_line":"                context, floatingip_db[\u0027fixed_port_id\u0027])"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"        if host and self._check_fips_availability_on_host_ext_net("},{"line_number":259,"context_line":"            context, host, floatingip_db[\u0027floating_network_id\u0027]):"},{"line_number":260,"context_line":"            LOG.debug(\u0027Deleting the Agent GW Port for ext-net: \u0027"},{"line_number":261,"context_line":"                      \u0027%s\u0027, floatingip_db[\u0027floating_network_id\u0027])"}],"source_content_type":"text/x-python","patch_set":11,"id":"3afb71cf_bf786790","line":258,"updated":"2015-06-08 16:42:05.000000000","message":"host can still be None at this point?","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"1335f04a91b90117848fb6eb2a85b7a359217d8d","unresolved":false,"context_lines":[{"line_number":255,"context_line":"            host \u003d self._get_vm_port_hostid("},{"line_number":256,"context_line":"                context, floatingip_db[\u0027fixed_port_id\u0027])"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"        if host and self._check_fips_availability_on_host_ext_net("},{"line_number":259,"context_line":"            context, host, floatingip_db[\u0027floating_network_id\u0027]):"},{"line_number":260,"context_line":"            LOG.debug(\u0027Deleting the Agent GW Port for ext-net: \u0027"},{"line_number":261,"context_line":"                      \u0027%s\u0027, floatingip_db[\u0027floating_network_id\u0027])"}],"source_content_type":"text/x-python","patch_set":11,"id":"3afb71cf_060e9a8b","line":258,"in_reply_to":"3afb71cf_bf786790","updated":"2015-06-10 21:54:21.000000000","message":"At this point I hope we will be getting the \"host\" info from Lin 255.\nSo I don\u0027t think host will be None at this Line 258.\n\nThere are some cases were the \"host\" information will be passed to teh _clear_unused_fip_agent_gw_port and in those conditions, we make sure if the \"host\" is valid and then pass the info to the \"_check_fips_availability_on_host_ext_net\".\n\nHope I answered your question.","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"}],"neutron/tests/unit/db/test_l3_dvr_db.py":[{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"30955faa7cd4b2da708096517b7f17491e88863b","unresolved":false,"context_lines":[{"line_number":395,"context_line":"                              \u0027_clear_unused_fip_agent_gw_port\u0027),"},{"line_number":396,"context_line":"            mock.patch.object(l3_dvr_db.l3_db.L3_NAT_db_mixin,"},{"line_number":397,"context_line":"                              \u0027_update_fip_assoc\u0027),"},{"line_number":398,"context_line":"                 ) as (grtr, vm_port, vf, upf):"},{"line_number":399,"context_line":"            grtr.return_value \u003d router"},{"line_number":400,"context_line":"            vm_port.return_value \u003d \u0027myhost\u0027, None"},{"line_number":401,"context_line":"            self.mixin._update_fip_assoc("}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_4e65f9b2","line":398,"updated":"2015-05-20 22:32:39.000000000","message":"these mock names are very hard to parse, can you please rename to something more readable?","commit_id":"002090c9f8e6473cde838ea274f4a186b8270edd"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"30955faa7cd4b2da708096517b7f17491e88863b","unresolved":false,"context_lines":[{"line_number":404,"context_line":"            self.assertTrue(upf.called)"},{"line_number":405,"context_line":""},{"line_number":406,"context_line":"    def test_migrate_floatingip_agent_port(self):"},{"line_number":407,"context_line":"        fip \u003d {"},{"line_number":408,"context_line":"            \u0027id\u0027: _uuid(),"},{"line_number":409,"context_line":"            \u0027port_id\u0027: 3241"},{"line_number":410,"context_line":"        }"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_6ebc35dc","line":407,"updated":"2015-05-20 22:32:39.000000000","message":"fip is really confusing, is it fixed or floating, I\u0027m always confused:(. I\u0027d like to request for better namings here..","commit_id":"002090c9f8e6473cde838ea274f4a186b8270edd"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"30955faa7cd4b2da708096517b7f17491e88863b","unresolved":false,"context_lines":[{"line_number":408,"context_line":"            \u0027id\u0027: _uuid(),"},{"line_number":409,"context_line":"            \u0027port_id\u0027: 3241"},{"line_number":410,"context_line":"        }"},{"line_number":411,"context_line":"        floatingip \u003d {"},{"line_number":412,"context_line":"            \u0027id\u0027: _uuid(),"},{"line_number":413,"context_line":"            \u0027fixed_port_id\u0027: 1234,"},{"line_number":414,"context_line":"            \u0027router_id\u0027: \u0027foo_router_id\u0027"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_4e33b9ab","line":411,"updated":"2015-05-20 22:32:39.000000000","message":"this is supposed to act as db obj right? can you please add _db suffix if so?","commit_id":"002090c9f8e6473cde838ea274f4a186b8270edd"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"30955faa7cd4b2da708096517b7f17491e88863b","unresolved":false,"context_lines":[{"line_number":419,"context_line":"            \u0027network_id\u0027: \u0027external_net\u0027"},{"line_number":420,"context_line":"        }"},{"line_number":421,"context_line":"        router \u003d {\u0027id\u0027: \u0027foo_router_id\u0027, \u0027distributed\u0027: True}"},{"line_number":422,"context_line":"        with contextlib.nested("},{"line_number":423,"context_line":"            mock.patch.object(self.mixin,"},{"line_number":424,"context_line":"                              \u0027get_router\u0027),"},{"line_number":425,"context_line":"            mock.patch.object(self.mixin,"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_4e8f392a","line":422,"updated":"2015-05-20 22:32:39.000000000","message":"this bunch of mocks is really suspicios, makes me feel like nothing is really tested though I know it is, but that\u0027s definitely not a good pattern to use. I\u0027ll add Maru and Assaf as they have beter vision on this","commit_id":"002090c9f8e6473cde838ea274f4a186b8270edd"},{"author":{"_account_id":6659,"name":"Paul Michali","email":"pc@michali.net","username":"pcm"},"change_message_id":"2ecd413fdd51e8d13d4c069c00ebfd88b48084d5","unresolved":false,"context_lines":[{"line_number":419,"context_line":"            \u0027network_id\u0027: \u0027external_net\u0027"},{"line_number":420,"context_line":"        }"},{"line_number":421,"context_line":"        router \u003d {\u0027id\u0027: \u0027foo_router_id\u0027, \u0027distributed\u0027: True}"},{"line_number":422,"context_line":"        with contextlib.nested("},{"line_number":423,"context_line":"            mock.patch.object(self.mixin,"},{"line_number":424,"context_line":"                              \u0027get_router\u0027),"},{"line_number":425,"context_line":"            mock.patch.object(self.mixin,"}],"source_content_type":"text/x-python","patch_set":10,"id":"7a016987_0e264868","line":422,"updated":"2015-05-27 14:24:38.000000000","message":"contextlib.nested() is being deprecated. Not sure if you want to revise just this usage (and the code on L389-398), fix all in module, or defer to a separate patch set.","commit_id":"68402b716de3819825c8feff161d752a5b3f63a5"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"a749ddca0d3931797328691fa56b981806f4660c","unresolved":false,"context_lines":[{"line_number":419,"context_line":"            \u0027network_id\u0027: \u0027external_net\u0027"},{"line_number":420,"context_line":"        }"},{"line_number":421,"context_line":"        router \u003d {\u0027id\u0027: \u0027foo_router_id\u0027, \u0027distributed\u0027: True}"},{"line_number":422,"context_line":"        with contextlib.nested("},{"line_number":423,"context_line":"            mock.patch.object(self.mixin,"},{"line_number":424,"context_line":"                              \u0027get_router\u0027),"},{"line_number":425,"context_line":"            mock.patch.object(self.mixin,"}],"source_content_type":"text/x-python","patch_set":10,"id":"7a016987_4ef4d959","line":422,"in_reply_to":"7a016987_0e264868","updated":"2015-05-29 18:21:25.000000000","message":"what would be the best thing to do.\nDo I need to change that as part of this patch or add in another patch to fix it for this file.","commit_id":"68402b716de3819825c8feff161d752a5b3f63a5"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"7456a88465c4e98e7a5a4880a5c736394ff06966","unresolved":false,"context_lines":[{"line_number":397,"context_line":"            vm_port_hosts.return_value \u003d \u0027myhost\u0027, None"},{"line_number":398,"context_line":"            self.mixin._update_fip_assoc("},{"line_number":399,"context_line":"                self.ctx, fip, floatingip, mock.ANY)"},{"line_number":400,"context_line":"            self.assertTrue(clear_gw_port.called)"},{"line_number":401,"context_line":"            self.assertTrue(update_fip_assoc.called)"},{"line_number":402,"context_line":""},{"line_number":403,"context_line":"    def test_migrate_floatingip_agent_port(self):"}],"source_content_type":"text/x-python","patch_set":11,"id":"3afb71cf_bb234d55","line":400,"updated":"2015-06-11 08:34:32.000000000","message":"IMO DB level tests should check for correct data presence/absence in DB, not for methods that were called - that\u0027s a wrong pattern for testing. In this case I\u0027d test that floating agent gateway port was created in DB first and then deleted on floating IP disassociation. I\u0027ll be happy to help with it, feel free to ping me over irc/email.","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"a1c97e21a3d8b2bb3915446aae30f6b0af9aa237","unresolved":false,"context_lines":[{"line_number":397,"context_line":"            vm_port_hosts.return_value \u003d \u0027myhost\u0027, None"},{"line_number":398,"context_line":"            self.mixin._update_fip_assoc("},{"line_number":399,"context_line":"                self.ctx, fip, floatingip, mock.ANY)"},{"line_number":400,"context_line":"            self.assertTrue(clear_gw_port.called)"},{"line_number":401,"context_line":"            self.assertTrue(update_fip_assoc.called)"},{"line_number":402,"context_line":""},{"line_number":403,"context_line":"    def test_migrate_floatingip_agent_port(self):"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_7ce2c430","line":400,"in_reply_to":"3afb71cf_bb234d55","updated":"2015-06-17 21:39:34.000000000","message":"Also Asaf brought up the same point and he created a patch for it.\nhttps://review.openstack.org/#/c/178880/\nThis is still under review. Once it gets in we can use that file and class to start writing the actual db based functional tests.","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"d457027818303f5d1515326ece6e7f911d6d43fe","unresolved":false,"context_lines":[{"line_number":397,"context_line":"            vm_port_hosts.return_value \u003d \u0027myhost\u0027, None"},{"line_number":398,"context_line":"            self.mixin._update_fip_assoc("},{"line_number":399,"context_line":"                self.ctx, fip, floatingip, mock.ANY)"},{"line_number":400,"context_line":"            self.assertTrue(clear_gw_port.called)"},{"line_number":401,"context_line":"            self.assertTrue(update_fip_assoc.called)"},{"line_number":402,"context_line":""},{"line_number":403,"context_line":"    def test_migrate_floatingip_agent_port(self):"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_9960fa02","line":400,"in_reply_to":"3afb71cf_bb234d55","updated":"2015-06-17 21:34:11.000000000","message":"hi Oleg, sure I might require your help.I will ping you in IRC.","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"},{"author":{"_account_id":5948,"name":"Oleg Bondarev","email":"obondarev@mirantis.com","username":"obondarev"},"change_message_id":"7456a88465c4e98e7a5a4880a5c736394ff06966","unresolved":false,"context_lines":[{"line_number":416,"context_line":"            \u0027network_id\u0027: \u0027external_net\u0027"},{"line_number":417,"context_line":"        }"},{"line_number":418,"context_line":"        router \u003d {\u0027id\u0027: \u0027foo_router_id\u0027, \u0027distributed\u0027: True}"},{"line_number":419,"context_line":"        with mock.patch.object(self.mixin,"},{"line_number":420,"context_line":"                              \u0027get_router\u0027) as grtr,\\"},{"line_number":421,"context_line":"                mock.patch.object("},{"line_number":422,"context_line":"                    self.mixin,"}],"source_content_type":"text/x-python","patch_set":11,"id":"3afb71cf_fba9c590","line":419,"updated":"2015-06-11 08:34:32.000000000","message":"same here: mocking everithing does not help us much to test that proper ports were created/deleted where needed.","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"d457027818303f5d1515326ece6e7f911d6d43fe","unresolved":false,"context_lines":[{"line_number":416,"context_line":"            \u0027network_id\u0027: \u0027external_net\u0027"},{"line_number":417,"context_line":"        }"},{"line_number":418,"context_line":"        router \u003d {\u0027id\u0027: \u0027foo_router_id\u0027, \u0027distributed\u0027: True}"},{"line_number":419,"context_line":"        with mock.patch.object(self.mixin,"},{"line_number":420,"context_line":"                              \u0027get_router\u0027) as grtr,\\"},{"line_number":421,"context_line":"                mock.patch.object("},{"line_number":422,"context_line":"                    self.mixin,"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_592d92a6","line":419,"in_reply_to":"3afb71cf_fba9c590","updated":"2015-06-17 21:34:11.000000000","message":"will ping you on IRC.","commit_id":"db74feac838d1009ebd686b674f3d3de9aff0806"}]}
