)]}'
{"dragonflow/controller/df_local_controller.py":[{"author":{"_account_id":23766,"name":"Dima Kuznetsov","email":"dima.kuznetsov@toganetworks.com","username":"dimak"},"change_message_id":"f832023a26cbeac9214e5c93164b3df791b3a930","unresolved":false,"context_lines":[{"line_number":458,"context_line":"    def update_floatingip(self, floatingip):"},{"line_number":459,"context_line":"        # check whether this floatingip is associated with a lport or not"},{"line_number":460,"context_line":"        fip_lport_id \u003d floatingip.get_lport_id()"},{"line_number":461,"context_line":"        if not fip_lport_id:"},{"line_number":462,"context_line":"            return"},{"line_number":463,"context_line":"        if not self.db_store.get_local_port(fip_lport_id):"},{"line_number":464,"context_line":"            return"},{"line_number":465,"context_line":"        old_floatingip \u003d self.db_store.get_floatingip(floatingip.get_id())"}],"source_content_type":"text/x-python","patch_set":4,"id":"da36d5c6_d67e97ad","line":462,"range":{"start_line":461,"start_character":0,"end_line":462,"end_character":18},"updated":"2017-02-20 07:44:13.000000000","message":"I think this means we cannot disassociate the FIP.\nAssume we have an associated FIP, now we want to disassociate it so we send an update with \u0027port_id\u0027: None, and the local controller does nothing.","commit_id":"be9889ecd432efc43aa152c4d8f1de8629d77afb"},{"author":{"_account_id":20287,"name":"hujie","email":"mike.hu@huawei.com","username":"hujie"},"change_message_id":"c61636bb6fee936aa08da80e4969438cd47a16f6","unresolved":false,"context_lines":[{"line_number":458,"context_line":"    def update_floatingip(self, floatingip):"},{"line_number":459,"context_line":"        # check whether this floatingip is associated with a lport or not"},{"line_number":460,"context_line":"        fip_lport_id \u003d floatingip.get_lport_id()"},{"line_number":461,"context_line":"        if not fip_lport_id:"},{"line_number":462,"context_line":"            return"},{"line_number":463,"context_line":"        if not self.db_store.get_local_port(fip_lport_id):"},{"line_number":464,"context_line":"            return"},{"line_number":465,"context_line":"        old_floatingip \u003d self.db_store.get_floatingip(floatingip.get_id())"}],"source_content_type":"text/x-python","patch_set":4,"id":"da36d5c6_f911ccb0","line":462,"range":{"start_line":461,"start_character":0,"end_line":462,"end_character":18},"in_reply_to":"da36d5c6_d67e97ad","updated":"2017-02-20 08:19:02.000000000","message":"yes, you are right, I\u0027ll re-organize the code, thx dima:)","commit_id":"be9889ecd432efc43aa152c4d8f1de8629d77afb"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"0d6b1c497a81a856385189180507370eaec63650","unresolved":false,"context_lines":[{"line_number":460,"context_line":"            return False"},{"line_number":461,"context_line":"        return True"},{"line_number":462,"context_line":""},{"line_number":463,"context_line":"    def _update_and_notify_fip(self, floatingip):"},{"line_number":464,"context_line":"        LOG.info(_LI(\"Floatingip is associated with port.\""},{"line_number":465,"context_line":"                     \"Floatingip \u003d %s\"), floatingip)"},{"line_number":466,"context_line":"        self.db_store.update_floatingip("}],"source_content_type":"text/x-python","patch_set":8,"id":"da36d5c6_673861f0","line":463,"range":{"start_line":463,"start_character":8,"end_line":463,"end_character":30},"updated":"2017-02-23 01:29:14.000000000","message":"Not sure I understand the change here, this is the same as former method _associate_floatingip, however the change of method name becomes vaguer.","commit_id":"7079f8940f36c85cf60b0f575b5638ea35620913"},{"author":{"_account_id":20287,"name":"hujie","email":"mike.hu@huawei.com","username":"hujie"},"change_message_id":"d9219d2bf48765ac7b0516fdd6417df1d5eb7f70","unresolved":false,"context_lines":[{"line_number":460,"context_line":"            return False"},{"line_number":461,"context_line":"        return True"},{"line_number":462,"context_line":""},{"line_number":463,"context_line":"    def _update_and_notify_fip(self, floatingip):"},{"line_number":464,"context_line":"        LOG.info(_LI(\"Floatingip is associated with port.\""},{"line_number":465,"context_line":"                     \"Floatingip \u003d %s\"), floatingip)"},{"line_number":466,"context_line":"        self.db_store.update_floatingip("}],"source_content_type":"text/x-python","patch_set":8,"id":"ba2be162_6d6478b8","line":463,"range":{"start_line":463,"start_character":8,"end_line":463,"end_character":30},"in_reply_to":"da36d5c6_673861f0","updated":"2017-03-05 11:31:34.000000000","message":"yes, maybe change a better name:)","commit_id":"7079f8940f36c85cf60b0f575b5638ea35620913"},{"author":{"_account_id":23766,"name":"Dima Kuznetsov","email":"dima.kuznetsov@toganetworks.com","username":"dimak"},"change_message_id":"137788d22f0324f2f09ebdb6582e9291eca26413","unresolved":false,"context_lines":[{"line_number":479,"context_line":"                self._update_and_notify_fip(floatingip)"},{"line_number":480,"context_line":"        else:"},{"line_number":481,"context_line":"            if floatingip.get_lport_id() !\u003d old_floatingip.get_lport_id():"},{"line_number":482,"context_line":"                self.open_flow_app.notify_disassociate_floatingip("},{"line_number":483,"context_line":"                    old_floatingip)"},{"line_number":484,"context_line":"                if fip_ready:"},{"line_number":485,"context_line":"                    self._update_and_notify_fip(floatingip)"},{"line_number":486,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"da36d5c6_a06ee3fe","line":483,"range":{"start_line":482,"start_character":0,"end_line":483,"end_character":35},"updated":"2017-02-22 11:20:02.000000000","message":"In case we have fip_ready \u003d False we don\u0027t store the updated fip in db_store which we always should as long as the update is relevant.\n\nI think to make it a bit easier, we should update fip in db_store right after we have verified its version.\n\nthen we have 2 possible actions:\n\n if old_fip.port is not None and old_fip.port !\u003d new_fip:\n     disassociate()\n\n if new_fip.port is not None:\n     associate()\n\nThis also takes care of the case where we missed an update of port_id to None.","commit_id":"7079f8940f36c85cf60b0f575b5638ea35620913"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"0d6b1c497a81a856385189180507370eaec63650","unresolved":false,"context_lines":[{"line_number":479,"context_line":"                self._update_and_notify_fip(floatingip)"},{"line_number":480,"context_line":"        else:"},{"line_number":481,"context_line":"            if floatingip.get_lport_id() !\u003d old_floatingip.get_lport_id():"},{"line_number":482,"context_line":"                self.open_flow_app.notify_disassociate_floatingip("},{"line_number":483,"context_line":"                    old_floatingip)"},{"line_number":484,"context_line":"                if fip_ready:"},{"line_number":485,"context_line":"                    self._update_and_notify_fip(floatingip)"},{"line_number":486,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"da36d5c6_e77611d6","line":483,"range":{"start_line":482,"start_character":0,"end_line":483,"end_character":35},"in_reply_to":"da36d5c6_a06ee3fe","updated":"2017-02-23 01:29:14.000000000","message":"+1 with the db store not get updated. But with dima\u0027s proposal, we might have extra associate action when\n\nold_fip.port is not None and old_fip.port \u003d\u003d new_fip.port\n\nthis might happen when fip\u0027s description(or some other fields) is updated.","commit_id":"7079f8940f36c85cf60b0f575b5638ea35620913"},{"author":{"_account_id":20287,"name":"hujie","email":"mike.hu@huawei.com","username":"hujie"},"change_message_id":"d9219d2bf48765ac7b0516fdd6417df1d5eb7f70","unresolved":false,"context_lines":[{"line_number":479,"context_line":"                self._update_and_notify_fip(floatingip)"},{"line_number":480,"context_line":"        else:"},{"line_number":481,"context_line":"            if floatingip.get_lport_id() !\u003d old_floatingip.get_lport_id():"},{"line_number":482,"context_line":"                self.open_flow_app.notify_disassociate_floatingip("},{"line_number":483,"context_line":"                    old_floatingip)"},{"line_number":484,"context_line":"                if fip_ready:"},{"line_number":485,"context_line":"                    self._update_and_notify_fip(floatingip)"},{"line_number":486,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"ba2be162_4d6174a8","line":483,"range":{"start_line":482,"start_character":0,"end_line":483,"end_character":35},"in_reply_to":"da36d5c6_e77611d6","updated":"2017-03-05 11:31:34.000000000","message":"well, in the old code before my patch, when the fip is not ready, it will return directly without store it into cache, so I kept this logic into my patch. So the all the old_fips are ready and I notify_disassociate_floatingip without checking it\u0027s ready, if you think it\u0027s necessary to store the fip when it\u0027s ready, I\u0027ll consider to add it:)","commit_id":"7079f8940f36c85cf60b0f575b5638ea35620913"}],"dragonflow/controller/dnat_app.py":[{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"0d6b1c497a81a856385189180507370eaec63650","unresolved":false,"context_lines":[{"line_number":492,"context_line":"        self._install_ingress_nat_rules(floatingip)"},{"line_number":493,"context_line":"        self._install_egress_nat_rules(floatingip)"},{"line_number":494,"context_line":""},{"line_number":495,"context_line":"    def _delete_floatingip(self, floatingip):"},{"line_number":496,"context_line":"        self.local_floatingips.pop(floatingip.get_id(), 0)"},{"line_number":497,"context_line":"        lport \u003d self.db_store.get_local_port(floatingip.get_lport_id())"},{"line_number":498,"context_line":"        mac \u003d lport.get_mac()"}],"source_content_type":"text/x-python","patch_set":8,"id":"da36d5c6_671f816c","line":495,"range":{"start_line":495,"start_character":8,"end_line":495,"end_character":26},"updated":"2017-02-23 01:29:14.000000000","message":"What is the meaning to add a \"private\" method _delete_floatingip here?","commit_id":"7079f8940f36c85cf60b0f575b5638ea35620913"},{"author":{"_account_id":20287,"name":"hujie","email":"mike.hu@huawei.com","username":"hujie"},"change_message_id":"d9219d2bf48765ac7b0516fdd6417df1d5eb7f70","unresolved":false,"context_lines":[{"line_number":492,"context_line":"        self._install_ingress_nat_rules(floatingip)"},{"line_number":493,"context_line":"        self._install_egress_nat_rules(floatingip)"},{"line_number":494,"context_line":""},{"line_number":495,"context_line":"    def _delete_floatingip(self, floatingip):"},{"line_number":496,"context_line":"        self.local_floatingips.pop(floatingip.get_id(), 0)"},{"line_number":497,"context_line":"        lport \u003d self.db_store.get_local_port(floatingip.get_lport_id())"},{"line_number":498,"context_line":"        mac \u003d lport.get_mac()"}],"source_content_type":"text/x-python","patch_set":8,"id":"ba2be162_cd756464","line":495,"range":{"start_line":495,"start_character":8,"end_line":495,"end_character":26},"in_reply_to":"da36d5c6_671f816c","updated":"2017-03-05 11:31:34.000000000","message":"In the old code, the delete_floatingip is both a publish method and also a private method, what\u0027s more, in my patch multi-places invoke the defined \"private\" _delete_floatingip, so I want to distinguish them.","commit_id":"7079f8940f36c85cf60b0f575b5638ea35620913"}]}
