)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"0952b809f5b4f63fd471ea8ff25b0368a8bbbc93","unresolved":false,"context_lines":[{"line_number":3,"context_line":"AuthorDate: 2016-04-19 15:22:58 +0800"},{"line_number":4,"context_line":"Commit:     yuanwei \u003cwei.yuan@huawei.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-04-19 16:12:30 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"this patch intend to solve bug #1571523, \"Changing VM to new SG is not"},{"line_number":8,"context_line":"working\""},{"line_number":9,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1a122d0e_412300bd","line":6,"updated":"2016-04-21 06:47:38.000000000","message":"Please explain what this change actually does, and include Closes-Bug: 1571523 as part of the commit message (or Partial-Bug: XXX or Related-Bug: XXX, whatever\u0027s relevant).","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":7805,"name":"Li Ma","email":"skywalker.nick@gmail.com","username":"Nick"},"change_message_id":"342bdcb092c11349e3d8cb41bbd0f12998dce21e","unresolved":false,"context_lines":[{"line_number":3,"context_line":"AuthorDate: 2016-04-19 15:22:58 +0800"},{"line_number":4,"context_line":"Commit:     yuanwei \u003cwei.yuan@huawei.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-04-19 16:12:30 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"this patch intend to solve bug #1571523, \"Changing VM to new SG is not"},{"line_number":8,"context_line":"working\""},{"line_number":9,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1a122d0e_a33621e5","line":6,"in_reply_to":"1a122d0e_412300bd","updated":"2016-04-22 06:51:04.000000000","message":"A title\n(blank line)\nA section of explanation about this problem and your solution.\n\nFinally,\nadd a \u0027Closes-Bug: #1571523\u0027","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"361e24b0ab48acf452d9db5cc08d2f2deb20b7eb","unresolved":false,"context_lines":[{"line_number":3,"context_line":"AuthorDate: 2016-04-19 15:22:58 +0800"},{"line_number":4,"context_line":"Commit:     yuanwei \u003cwei.yuan@huawei.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-04-19 16:12:30 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"this patch intend to solve bug #1571523, \"Changing VM to new SG is not"},{"line_number":8,"context_line":"working\""},{"line_number":9,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1a122d0e_973e76d8","line":6,"in_reply_to":"1a122d0e_a33621e5","updated":"2016-04-25 13:17:09.000000000","message":"ok","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":7805,"name":"Li Ma","email":"skywalker.nick@gmail.com","username":"Nick"},"change_message_id":"342bdcb092c11349e3d8cb41bbd0f12998dce21e","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"this patch intend to solve bug #1571523, \"Changing VM to new SG is not"},{"line_number":8,"context_line":"working\""},{"line_number":9,"context_line":""},{"line_number":10,"context_line":"Change-Id: I38ccb4f3f761a20fd9f269367d3097240d5d9bc7"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1a122d0e_232a117f","line":9,"updated":"2016-04-22 06:51:04.000000000","message":"Closes-Bug: #1571523","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"361e24b0ab48acf452d9db5cc08d2f2deb20b7eb","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"this patch intend to solve bug #1571523, \"Changing VM to new SG is not"},{"line_number":8,"context_line":"working\""},{"line_number":9,"context_line":""},{"line_number":10,"context_line":"Change-Id: I38ccb4f3f761a20fd9f269367d3097240d5d9bc7"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1a122d0e_f7252ac2","line":9,"in_reply_to":"1a122d0e_232a117f","updated":"2016-04-25 13:17:09.000000000","message":"ok","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"}],"dragonflow/controller/df_base_app.py":[{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"0952b809f5b4f63fd471ea8ff25b0368a8bbbc93","unresolved":false,"context_lines":[{"line_number":38,"context_line":"        :param lport:           local logical port which is updated to db"},{"line_number":39,"context_line":"        :param original_lport:  local logical port in db before the update"},{"line_number":40,"context_line":"        \"\"\""},{"line_number":41,"context_line":"        self.add_local_port(lport)"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"    def update_remote_port(self, lport, original_lport):"},{"line_number":44,"context_line":"        \"\"\"update remote logical port hook callback"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_c1a6f0bf","line":41,"updated":"2016-04-21 06:47:38.000000000","message":"What happens if the application doesn\u0027t implement add_local_port? What if the application doesn\u0027t want to implement update (The app may only need to be notified that the port exists, but it doesn\u0027t care if the port changes).","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"361e24b0ab48acf452d9db5cc08d2f2deb20b7eb","unresolved":false,"context_lines":[{"line_number":38,"context_line":"        :param lport:           local logical port which is updated to db"},{"line_number":39,"context_line":"        :param original_lport:  local logical port in db before the update"},{"line_number":40,"context_line":"        \"\"\""},{"line_number":41,"context_line":"        self.add_local_port(lport)"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"    def update_remote_port(self, lport, original_lport):"},{"line_number":44,"context_line":"        \"\"\"update remote logical port hook callback"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_3ae667b4","line":41,"in_reply_to":"1a122d0e_c1a6f0bf","updated":"2016-04-25 13:17:09.000000000","message":"There was no update_local_port event in old codes, so the applications\u0027 process when a port was updated was just same as that when a port was created. So choosing calling add_local_port method by default may be a more suitable way. If there is a application that doesn\u0027t care if the port changes, it can simply implement a empty update_local_port method in its app.","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"0952b809f5b4f63fd471ea8ff25b0368a8bbbc93","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        :param original_lport:  logical port in db which resides on other"},{"line_number":49,"context_line":"        compute node before the update"},{"line_number":50,"context_line":"        \"\"\""},{"line_number":51,"context_line":"        self.add_remote_port(lport)"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"    def get_datapath(self):"},{"line_number":54,"context_line":"        return self.api.datapath"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_21aa4485","line":51,"updated":"2016-04-21 06:47:38.000000000","message":"Same as above for remote ports.","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"361e24b0ab48acf452d9db5cc08d2f2deb20b7eb","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        :param original_lport:  logical port in db which resides on other"},{"line_number":49,"context_line":"        compute node before the update"},{"line_number":50,"context_line":"        \"\"\""},{"line_number":51,"context_line":"        self.add_remote_port(lport)"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"    def get_datapath(self):"},{"line_number":54,"context_line":"        return self.api.datapath"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_5af1a369","line":51,"in_reply_to":"1a122d0e_21aa4485","updated":"2016-04-25 13:17:09.000000000","message":"same as above","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":20405,"name":"liuhaixia","email":"liuhaixia315@huawei.com","username":"liuhaixia"},"change_message_id":"f6d13f67157bc7a4e71bf31d224a6b87ba524238","unresolved":false,"context_lines":[{"line_number":35,"context_line":"        \"\"\"override update_local_port method to default call add_local_port"},{"line_number":36,"context_line":"        method"},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"        :param lport:           local logical port which is updated to db"},{"line_number":39,"context_line":"        :param original_lport:  local logical port in db before the update"},{"line_number":40,"context_line":"        \"\"\""},{"line_number":41,"context_line":"        self.add_local_port(lport)"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"    def update_remote_port(self, lport, original_lport):"},{"line_number":44,"context_line":"        \"\"\"update remote logical port hook callback"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_3a14d742","line":41,"range":{"start_line":38,"start_character":3,"end_line":41,"end_character":34},"updated":"2016-05-09 06:42:42.000000000","message":"Why implements this method in DFLowApp?\nIf only update security group, other apps do not care, they do not need to handle thus event.\nSo ,if call add_loca_port as default behavior, other app like L2App, will handle event that they don\u0027t care.","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"cbdc7a4dd96297271355bd3c29a817d298d64aa0","unresolved":false,"context_lines":[{"line_number":35,"context_line":"        \"\"\"override update_local_port method to default call add_local_port"},{"line_number":36,"context_line":"        method"},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"        :param lport:           local logical port which is updated to db"},{"line_number":39,"context_line":"        :param original_lport:  local logical port in db before the update"},{"line_number":40,"context_line":"        \"\"\""},{"line_number":41,"context_line":"        self.add_local_port(lport)"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"    def update_remote_port(self, lport, original_lport):"},{"line_number":44,"context_line":"        \"\"\"update remote logical port hook callback"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_a0025607","line":41,"range":{"start_line":38,"start_character":3,"end_line":41,"end_character":34},"in_reply_to":"dab17558_3a14d742","updated":"2016-05-09 07:04:48.000000000","message":"As explained above. Pasted here: There was no update_local_port event in old codes, so the applications\u0027 process when a port was updated was just same as that when a port was created. So choosing calling add_local_port method by default may be a more suitable way. If there is a application that doesn\u0027t care if the port changes, it can simply implement a empty update_local_port method in its app.","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"},{"author":{"_account_id":20405,"name":"liuhaixia","email":"liuhaixia315@huawei.com","username":"liuhaixia"},"change_message_id":"f6d13f67157bc7a4e71bf31d224a6b87ba524238","unresolved":false,"context_lines":[{"line_number":46,"context_line":"        :param lport:           logical port which resides on other compute"},{"line_number":47,"context_line":"        node, and is updated in db"},{"line_number":48,"context_line":"        :param original_lport:  logical port in db which resides on other"},{"line_number":49,"context_line":"        compute node before the update"},{"line_number":50,"context_line":"        \"\"\""},{"line_number":51,"context_line":"        self.add_remote_port(lport)"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"    def get_datapath(self):"},{"line_number":54,"context_line":"        return self.api.datapath"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_1a0f532f","line":51,"range":{"start_line":49,"start_character":3,"end_line":51,"end_character":35},"updated":"2016-05-09 06:42:42.000000000","message":"As above.","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"}],"dragonflow/controller/df_local_controller.py":[{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"0952b809f5b4f63fd471ea8ff25b0368a8bbbc93","unresolved":false,"context_lines":[{"line_number":148,"context_line":"        for t_port in t_ports:"},{"line_number":149,"context_line":"            if t_port.get_chassis_id() \u003d\u003d remote_chassis_name:"},{"line_number":150,"context_line":"                LOG.info(_LI(\"remote Chassis Tunnel already installed  \u003d %s\") %"},{"line_number":151,"context_line":"                         chassis.__str__())"},{"line_number":152,"context_line":"                return"},{"line_number":153,"context_line":"        # Create tunnel port to this chassis"},{"line_number":154,"context_line":"        LOG.info(_LI(\"Adding tunnel to remote chassis \u003d %s\") %"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_a175b432","line":151,"updated":"2016-04-21 06:47:38.000000000","message":"If you\u0027re already changing the line, please change to chassis.__str__() -\u003e str(chassis)","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"361e24b0ab48acf452d9db5cc08d2f2deb20b7eb","unresolved":false,"context_lines":[{"line_number":148,"context_line":"        for t_port in t_ports:"},{"line_number":149,"context_line":"            if t_port.get_chassis_id() \u003d\u003d remote_chassis_name:"},{"line_number":150,"context_line":"                LOG.info(_LI(\"remote Chassis Tunnel already installed  \u003d %s\") %"},{"line_number":151,"context_line":"                         chassis.__str__())"},{"line_number":152,"context_line":"                return"},{"line_number":153,"context_line":"        # Create tunnel port to this chassis"},{"line_number":154,"context_line":"        LOG.info(_LI(\"Adding tunnel to remote chassis \u003d %s\") %"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_3759625b","line":151,"in_reply_to":"1a122d0e_a175b432","updated":"2016-04-25 13:17:09.000000000","message":"ok","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"0952b809f5b4f63fd471ea8ff25b0368a8bbbc93","unresolved":false,"context_lines":[{"line_number":176,"context_line":"            lswitch.get_id(),"},{"line_number":177,"context_line":"        )"},{"line_number":178,"context_line":"        lswitch_conf \u003d {\u0027network_id\u0027: network_id,"},{"line_number":179,"context_line":"                        \u0027lswitch\u0027: lswitch.__str__()}"},{"line_number":180,"context_line":"        LOG.info(_LI(\"Adding/Updating Logical Switch \u003d %s\") % lswitch_conf)"},{"line_number":181,"context_line":"        self.db_store.set_lswitch(lswitch.get_id(), lswitch)"},{"line_number":182,"context_line":"        self.open_flow_app.notify_update_logical_switch(lswitch)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_81707841","line":179,"updated":"2016-04-21 06:47:38.000000000","message":"Same here re: str and __str__","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"361e24b0ab48acf452d9db5cc08d2f2deb20b7eb","unresolved":false,"context_lines":[{"line_number":176,"context_line":"            lswitch.get_id(),"},{"line_number":177,"context_line":"        )"},{"line_number":178,"context_line":"        lswitch_conf \u003d {\u0027network_id\u0027: network_id,"},{"line_number":179,"context_line":"                        \u0027lswitch\u0027: lswitch.__str__()}"},{"line_number":180,"context_line":"        LOG.info(_LI(\"Adding/Updating Logical Switch \u003d %s\") % lswitch_conf)"},{"line_number":181,"context_line":"        self.db_store.set_lswitch(lswitch.get_id(), lswitch)"},{"line_number":182,"context_line":"        self.open_flow_app.notify_update_logical_switch(lswitch)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_77311a0b","line":179,"in_reply_to":"1a122d0e_81707841","updated":"2016-04-25 13:17:09.000000000","message":"ok","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"0952b809f5b4f63fd471ea8ff25b0368a8bbbc93","unresolved":false,"context_lines":[{"line_number":216,"context_line":"                             {\u0027port\u0027: str(lport),"},{"line_number":217,"context_line":"                              \u0027original_port\u0027: str(original_lport)})"},{"line_number":218,"context_line":"                    self.open_flow_app.notify_update_local_port(lport,"},{"line_number":219,"context_line":"                                                                original_lport)"},{"line_number":220,"context_line":"            else:"},{"line_number":221,"context_line":"                LOG.info(_LI(\"Local logical port %s was not created yet\") %"},{"line_number":222,"context_line":"                         str(lport))"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_e1dfac0a","line":219,"updated":"2016-04-21 06:47:38.000000000","message":"Consider changing in api_nb.py to call logical_port_updated and logical_port_created according to the correct event, rather than trying to infer it heuristically.","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"361e24b0ab48acf452d9db5cc08d2f2deb20b7eb","unresolved":false,"context_lines":[{"line_number":216,"context_line":"                             {\u0027port\u0027: str(lport),"},{"line_number":217,"context_line":"                              \u0027original_port\u0027: str(original_lport)})"},{"line_number":218,"context_line":"                    self.open_flow_app.notify_update_local_port(lport,"},{"line_number":219,"context_line":"                                                                original_lport)"},{"line_number":220,"context_line":"            else:"},{"line_number":221,"context_line":"                LOG.info(_LI(\"Local logical port %s was not created yet\") %"},{"line_number":222,"context_line":"                         str(lport))"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_97b9567c","line":219,"in_reply_to":"1a122d0e_e1dfac0a","updated":"2016-04-25 13:17:09.000000000","message":"ok","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":13070,"name":"Eran Gampel","email":"eran@gampel.net","username":"Gampel"},"change_message_id":"a96a593652aaba652312ac10e7bdbe5c823d702d","unresolved":false,"context_lines":[{"line_number":148,"context_line":"        for t_port in t_ports:"},{"line_number":149,"context_line":"            if t_port.get_chassis_id() \u003d\u003d remote_chassis_name:"},{"line_number":150,"context_line":"                LOG.info(_LI(\"remote Chassis Tunnel already installed  \u003d %s\") %"},{"line_number":151,"context_line":"                         str(chassis))"},{"line_number":152,"context_line":"                return"},{"line_number":153,"context_line":"        # Create tunnel port to this chassis"},{"line_number":154,"context_line":"        LOG.info(_LI(\"Adding tunnel to remote chassis \u003d %s\") %"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_4e92ab9f","line":151,"range":{"start_line":151,"start_character":25,"end_line":151,"end_character":28},"updated":"2016-05-09 15:13:16.000000000","message":"This fix is unrelated and I am not sure why we need it","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"},{"author":{"_account_id":13070,"name":"Eran Gampel","email":"eran@gampel.net","username":"Gampel"},"change_message_id":"a96a593652aaba652312ac10e7bdbe5c823d702d","unresolved":false,"context_lines":[{"line_number":176,"context_line":"            lswitch.get_id(),"},{"line_number":177,"context_line":"        )"},{"line_number":178,"context_line":"        lswitch_conf \u003d {\u0027network_id\u0027: network_id,"},{"line_number":179,"context_line":"                        \u0027lswitch\u0027: str(lswitch)}"},{"line_number":180,"context_line":"        LOG.info(_LI(\"Adding/Updating Logical Switch \u003d %s\") % lswitch_conf)"},{"line_number":181,"context_line":"        self.db_store.set_lswitch(lswitch.get_id(), lswitch)"},{"line_number":182,"context_line":"        self.open_flow_app.notify_update_logical_switch(lswitch)"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_6eedef24","line":179,"range":{"start_line":179,"start_character":34,"end_line":179,"end_character":48},"updated":"2016-05-09 15:13:16.000000000","message":"unrelated","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"}],"dragonflow/controller/sg_app.py":[{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"0952b809f5b4f63fd471ea8ff25b0368a8bbbc93","unresolved":false,"context_lines":[{"line_number":1005,"context_line":"            self._get_added_and_removed_secgroups(secgroups,"},{"line_number":1006,"context_line":"                                                  original_secgroups)"},{"line_number":1007,"context_line":""},{"line_number":1008,"context_line":"        if (secgroups is None) and (original_secgroups is not None):"},{"line_number":1009,"context_line":"            # uninstall ct table"},{"line_number":1010,"context_line":"            self._uninstall_connection_track_flows(lport)"},{"line_number":1011,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_6161dc04","line":1008,"updated":"2016-04-21 06:47:38.000000000","message":"What happens if secgroups \u003d\u003d []? It is not None, but I think this case is still interesting.\n\nThis point repeats throughout this file.","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"361e24b0ab48acf452d9db5cc08d2f2deb20b7eb","unresolved":false,"context_lines":[{"line_number":1005,"context_line":"            self._get_added_and_removed_secgroups(secgroups,"},{"line_number":1006,"context_line":"                                                  original_secgroups)"},{"line_number":1007,"context_line":""},{"line_number":1008,"context_line":"        if (secgroups is None) and (original_secgroups is not None):"},{"line_number":1009,"context_line":"            # uninstall ct table"},{"line_number":1010,"context_line":"            self._uninstall_connection_track_flows(lport)"},{"line_number":1011,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"1a122d0e_3aa0279f","line":1008,"in_reply_to":"1a122d0e_6161dc04","updated":"2016-04-25 13:17:09.000000000","message":"According to the logic of codes in plugin, \"secgroups \u003d\u003d []\" will be transformed to \"secgroups \u003d\u003d None\". But for robustness, I will change codes compatible with this case.","commit_id":"3f3f4e34a5a46b73b780a2104c2f7f5bc3232252"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"45506022b5c3c6570b90cfa664507b21824553d8","unresolved":false,"context_lines":[{"line_number":952,"context_line":""},{"line_number":953,"context_line":"    def _get_added_and_removed_secgroups(self, secgroups, original_secgroups):"},{"line_number":954,"context_line":"        added_secgroups \u003d []"},{"line_number":955,"context_line":"        if not self._is_security_groups_none_or_empty(original_secgroups):"},{"line_number":956,"context_line":"            removed_secgroups \u003d list(original_secgroups)"},{"line_number":957,"context_line":"        else:"},{"line_number":958,"context_line":"            removed_secgroups \u003d []"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a122d0e_a2523b65","line":955,"updated":"2016-04-26 10:49:33.000000000","message":"You can just use \u0027if not original_secgroups:\u0027\nThe condition holds if original_secgroups \u003d\u003d [].","commit_id":"b94e4f815f0e08b09d781a1a49c156a747ce5dea"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"a12f569759078f6c24daac72f3752a1f93a64ff9","unresolved":false,"context_lines":[{"line_number":955,"context_line":""},{"line_number":956,"context_line":"    def _get_added_and_removed_secgroups(self, secgroups, original_secgroups):"},{"line_number":957,"context_line":"        added_secgroups \u003d []"},{"line_number":958,"context_line":"        if original_secgroups is not None:"},{"line_number":959,"context_line":"            removed_secgroups \u003d list(original_secgroups)"},{"line_number":960,"context_line":"        else:"},{"line_number":961,"context_line":"            removed_secgroups \u003d []"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_dd7145aa","line":958,"updated":"2016-05-09 06:09:20.000000000","message":"I\u0027m curious: Why did you change this line?","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"e930b3f6ea59e0125378654182014b8198ee94c4","unresolved":false,"context_lines":[{"line_number":955,"context_line":""},{"line_number":956,"context_line":"    def _get_added_and_removed_secgroups(self, secgroups, original_secgroups):"},{"line_number":957,"context_line":"        added_secgroups \u003d []"},{"line_number":958,"context_line":"        if original_secgroups is not None:"},{"line_number":959,"context_line":"            removed_secgroups \u003d list(original_secgroups)"},{"line_number":960,"context_line":"        else:"},{"line_number":961,"context_line":"            removed_secgroups \u003d []"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_fd352946","line":958,"in_reply_to":"dab17558_dd7145aa","updated":"2016-05-09 06:32:18.000000000","message":"\"if not original_secgroups\" take effect when original_secgroups is None, which is opposite to the expected.","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"dc5048616747f6bc75ae132e6d90902b879bbe28","unresolved":false,"context_lines":[{"line_number":955,"context_line":""},{"line_number":956,"context_line":"    def _get_added_and_removed_secgroups(self, secgroups, original_secgroups):"},{"line_number":957,"context_line":"        added_secgroups \u003d []"},{"line_number":958,"context_line":"        if original_secgroups is not None:"},{"line_number":959,"context_line":"            removed_secgroups \u003d list(original_secgroups)"},{"line_number":960,"context_line":"        else:"},{"line_number":961,"context_line":"            removed_secgroups \u003d []"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_a1b18f91","line":958,"in_reply_to":"dab17558_fd352946","updated":"2016-05-10 05:12:03.000000000","message":"Right. Missed that. Sorry. :)","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"},{"author":{"_account_id":20405,"name":"liuhaixia","email":"liuhaixia315@huawei.com","username":"liuhaixia"},"change_message_id":"f6d13f67157bc7a4e71bf31d224a6b87ba524238","unresolved":false,"context_lines":[{"line_number":1022,"context_line":"        for secgroup_id in added_secgroups:"},{"line_number":1023,"context_line":"            self._add_local_port_associating(lport, secgroup_id)"},{"line_number":1024,"context_line":""},{"line_number":1025,"context_line":"        for secgroup_id in removed_secgroups:"},{"line_number":1026,"context_line":"            self._remove_local_port_associating(lport, secgroup_id)"},{"line_number":1027,"context_line":""},{"line_number":1028,"context_line":"        if (not self._is_security_groups_none_or_empty(secgroups)) and \\"},{"line_number":1029,"context_line":"                self._is_security_groups_none_or_empty(original_secgroups):"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_7dabf91d","line":1026,"range":{"start_line":1025,"start_character":0,"end_line":1026,"end_character":67},"updated":"2016-05-09 06:42:42.000000000","message":"Can this happens? You add a new rule, then remove an old rule, will the remove actions delete the rule you just added if the two rules have some relationships?","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"cbdc7a4dd96297271355bd3c29a817d298d64aa0","unresolved":false,"context_lines":[{"line_number":1022,"context_line":"        for secgroup_id in added_secgroups:"},{"line_number":1023,"context_line":"            self._add_local_port_associating(lport, secgroup_id)"},{"line_number":1024,"context_line":""},{"line_number":1025,"context_line":"        for secgroup_id in removed_secgroups:"},{"line_number":1026,"context_line":"            self._remove_local_port_associating(lport, secgroup_id)"},{"line_number":1027,"context_line":""},{"line_number":1028,"context_line":"        if (not self._is_security_groups_none_or_empty(secgroups)) and \\"},{"line_number":1029,"context_line":"                self._is_security_groups_none_or_empty(original_secgroups):"}],"source_content_type":"text/x-python","patch_set":5,"id":"dab17558_e0b73ef3","line":1026,"range":{"start_line":1025,"start_character":0,"end_line":1026,"end_character":67},"in_reply_to":"dab17558_7dabf91d","updated":"2016-05-09 07:04:48.000000000","message":"Codes in there is not about creation/removal of rules, but binding/unbinding security groups of a port. You can update a port of changing it\u0027s binding security groups from SG_A, SG_B to SG_B, SG_C only by one command, and the plugin will also process this command only by one event. In that case, SG_A will be the \"removed_secgroups\" of this port.","commit_id":"37467176ccb0e29ea752a8a766b3e243f6e3d226"}],"dragonflow/db/api_nb.py":[{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"45506022b5c3c6570b90cfa664507b21824553d8","unresolved":false,"context_lines":[{"line_number":198,"context_line":"            if action \u003d\u003d \u0027create\u0027:"},{"line_number":199,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":200,"context_line":"                self.controller.logical_port_created(lport)"},{"line_number":201,"context_line":"            elif action \u003d\u003d action \u003d\u003d \u0027set\u0027:"},{"line_number":202,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":203,"context_line":"                self.controller.logical_port_updated(lport)"},{"line_number":204,"context_line":"            elif action \u003d\u003d \u0027delete\u0027:"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a122d0e_58119903","line":201,"updated":"2016-04-26 10:49:33.000000000","message":"Why not simply use action \u003d\u003d \u0027set\u0027?","commit_id":"b94e4f815f0e08b09d781a1a49c156a747ce5dea"},{"author":{"_account_id":18903,"name":"Yuli","email":"stremovsky@gmail.com","username":"yuli"},"change_message_id":"f187d1f2d8e497c23826874725d333e7fc7f56d3","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        elif \u0027lport\u0027 \u003d\u003d table:"},{"line_number":199,"context_line":"            if action \u003d\u003d \u0027create\u0027:"},{"line_number":200,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":201,"context_line":"                self.controller.logical_port_created(lport)"},{"line_number":202,"context_line":"            elif action \u003d\u003d \u0027set\u0027:"},{"line_number":203,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":204,"context_line":"                self.controller.logical_port_updated(lport)"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a122d0e_ce0ea78b","line":201,"range":{"start_line":201,"start_character":32,"end_line":201,"end_character":52},"updated":"2016-05-04 11:25:40.000000000","message":"I am not sure that logical_port_created good here.\nWhy u can not use logical_port_updated here ?","commit_id":"84211bd81839d9767ab80940c8a7fbe79fc44b65"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"dd859d1c12ee596bd23208cf539d5ea75bfa6b70","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        elif \u0027lport\u0027 \u003d\u003d table:"},{"line_number":199,"context_line":"            if action \u003d\u003d \u0027create\u0027:"},{"line_number":200,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":201,"context_line":"                self.controller.logical_port_created(lport)"},{"line_number":202,"context_line":"            elif action \u003d\u003d \u0027set\u0027:"},{"line_number":203,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":204,"context_line":"                self.controller.logical_port_updated(lport)"}],"source_content_type":"text/x-python","patch_set":4,"id":"dab17558_0b326c10","line":201,"range":{"start_line":201,"start_character":32,"end_line":201,"end_character":52},"in_reply_to":"1a122d0e_7b6f2ac4","updated":"2016-05-08 20:22:35.000000000","message":"I stand by my original comment - the action is create, so calling logical_port_created seems more logical.","commit_id":"84211bd81839d9767ab80940c8a7fbe79fc44b65"},{"author":{"_account_id":21007,"name":"yuan wei","email":"wei.yuan@huawei.com","username":"yuanwei"},"change_message_id":"54c9dfd8aabcc00878dc1f370b4da742942aa7d1","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        elif \u0027lport\u0027 \u003d\u003d table:"},{"line_number":199,"context_line":"            if action \u003d\u003d \u0027create\u0027:"},{"line_number":200,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":201,"context_line":"                self.controller.logical_port_created(lport)"},{"line_number":202,"context_line":"            elif action \u003d\u003d \u0027set\u0027:"},{"line_number":203,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":204,"context_line":"                self.controller.logical_port_updated(lport)"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a122d0e_7b6f2ac4","line":201,"range":{"start_line":201,"start_character":32,"end_line":201,"end_character":52},"in_reply_to":"1a122d0e_94015e07","updated":"2016-05-05 01:54:03.000000000","message":"Calling logical_port_updated also works well here. But as Omer suggested to patch set 1, distinguishing \"logical_port_created\" from \"logical_port_updated\" is clearer.","commit_id":"84211bd81839d9767ab80940c8a7fbe79fc44b65"},{"author":{"_account_id":20297,"name":"duankebo","email":"duankebo@huawei.com","username":"duankebo"},"change_message_id":"e09c4c500538aa412a7169a3535a1235e04c235d","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        elif \u0027lport\u0027 \u003d\u003d table:"},{"line_number":199,"context_line":"            if action \u003d\u003d \u0027create\u0027:"},{"line_number":200,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":201,"context_line":"                self.controller.logical_port_created(lport)"},{"line_number":202,"context_line":"            elif action \u003d\u003d \u0027set\u0027:"},{"line_number":203,"context_line":"                lport \u003d LogicalPort(value)"},{"line_number":204,"context_line":"                self.controller.logical_port_updated(lport)"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a122d0e_94015e07","line":201,"range":{"start_line":201,"start_character":32,"end_line":201,"end_character":52},"in_reply_to":"1a122d0e_ce0ea78b","updated":"2016-05-04 12:16:26.000000000","message":"+1, I have the same puzzle.","commit_id":"84211bd81839d9767ab80940c8a7fbe79fc44b65"}]}
