)]}'
{"networking_ovn/ml2/mech_driver.py":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"5bef09788b0b9b28880e04b9ba4420d5f611e0e9","unresolved":false,"context_lines":[{"line_number":583,"context_line":"            admin_context \u003d n_context.get_admin_context()"},{"line_number":584,"context_line":"            try:"},{"line_number":585,"context_line":"                port \u003d self._plugin.get_port(admin_context, parent_port)"},{"line_number":586,"context_line":"                host_id \u003d port[\u0027binding:host_id\u0027]"},{"line_number":587,"context_line":"                subport \u003d {\u0027id\u0027: port_id,"},{"line_number":588,"context_line":"                           \u0027port\u0027: {\u0027binding:host_id\u0027: host_id}}"},{"line_number":589,"context_line":"                self._plugin.update_port(admin_context, port_id, subport)"}],"source_content_type":"text/x-python","patch_set":3,"id":"bf3e73b7_2221c5fc","line":586,"updated":"2017-08-07 09:54:12.000000000","message":"I was thinking that this could, may be fail if you don\u0027t have yet the binding:host_id on portis not set. But I guess we can assume it will be there (port going up)? :)","commit_id":"122d12e900a1c39ef9fd9d1ac9a72314fcf3d027"},{"author":{"_account_id":23804,"name":"Daniel Alvarez","email":"dalvarez@redhat.com","username":"dalvarez"},"change_message_id":"2dd26d1a02c3aa70f55f146b0c79c60381103783","unresolved":false,"context_lines":[{"line_number":583,"context_line":"            admin_context \u003d n_context.get_admin_context()"},{"line_number":584,"context_line":"            try:"},{"line_number":585,"context_line":"                port \u003d self._plugin.get_port(admin_context, parent_port)"},{"line_number":586,"context_line":"                host_id \u003d port[\u0027binding:host_id\u0027]"},{"line_number":587,"context_line":"                subport \u003d {\u0027id\u0027: port_id,"},{"line_number":588,"context_line":"                           \u0027port\u0027: {\u0027binding:host_id\u0027: host_id}}"},{"line_number":589,"context_line":"                self._plugin.update_port(admin_context, port_id, subport)"}],"source_content_type":"text/x-python","patch_set":3,"id":"bf3e73b7_bdc03652","line":586,"in_reply_to":"bf3e73b7_2221c5fc","updated":"2017-08-07 09:57:07.000000000","message":"Could be, i\u0027ll think it again :)","commit_id":"122d12e900a1c39ef9fd9d1ac9a72314fcf3d027"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"5fa85f61d4939d76d602dcf16e62835559316eb4","unresolved":false,"context_lines":[{"line_number":583,"context_line":"            admin_context \u003d n_context.get_admin_context()"},{"line_number":584,"context_line":"            try:"},{"line_number":585,"context_line":"                port \u003d self._plugin.get_port(admin_context, parent_port)"},{"line_number":586,"context_line":"                host_id \u003d port[\u0027binding:host_id\u0027]"},{"line_number":587,"context_line":"                subport \u003d {\u0027id\u0027: port_id,"},{"line_number":588,"context_line":"                           \u0027port\u0027: {\u0027binding:host_id\u0027: host_id}}"},{"line_number":589,"context_line":"                self._plugin.update_port(admin_context, port_id, subport)"}],"source_content_type":"text/x-python","patch_set":3,"id":"bf3e73b7_b33bc59a","line":586,"in_reply_to":"bf3e73b7_bdc03652","updated":"2017-08-07 11:12:05.000000000","message":"from neutron_lib.api.definitions import portbindings\nhost_id\u003dport.get(portbindings.HOST_ID)\n\nuse portbindings.HOST_ID instead of \u0027binding:host_id\u0027","commit_id":"122d12e900a1c39ef9fd9d1ac9a72314fcf3d027"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"ac3c536a25b95cb4839ed550ca90b024949a90f2","unresolved":false,"context_lines":[{"line_number":584,"context_line":"            try:"},{"line_number":585,"context_line":"                port \u003d self._plugin.get_port(admin_context, parent_port)"},{"line_number":586,"context_line":"                host_id \u003d port.get(portbindings.HOST_ID, \u0027\u0027)"},{"line_number":587,"context_line":"                subport \u003d {\u0027id\u0027: port_id,"},{"line_number":588,"context_line":"                           \u0027port\u0027: {\u0027binding:host_id\u0027: host_id}}"},{"line_number":589,"context_line":"                self._plugin.update_port(admin_context, port_id, subport)"},{"line_number":590,"context_line":"            except (os_db_exc.DBReferenceError, n_exc.PortNotFound):"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f436f4f_7ca17ba9","line":587,"updated":"2017-08-10 11:58:29.000000000","message":"Can\u0027t we call update_port only if host_id is not \u0027\u0027 i.e\nif host_id:\n   subport \u003d {\u0027id\u0027: port_id, port\u0027: {\u0027binding:host_id\u0027: host_id}}\n   self._plugin.update_port(admin_context, port_id, subport)\n\nAnd also call update_port() only if host is not already set in the subport?","commit_id":"475a7b69eb2382a4667e6b58a795a796174482da"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"ae1fa55a11b3a0781c3d14f40237f3fd6ded08b3","unresolved":false,"context_lines":[{"line_number":584,"context_line":"            try:"},{"line_number":585,"context_line":"                port \u003d self._plugin.get_port(admin_context, parent_port)"},{"line_number":586,"context_line":"                host_id \u003d port.get(portbindings.HOST_ID, \u0027\u0027)"},{"line_number":587,"context_line":"                subport \u003d {\u0027id\u0027: port_id,"},{"line_number":588,"context_line":"                           \u0027port\u0027: {\u0027binding:host_id\u0027: host_id}}"},{"line_number":589,"context_line":"                self._plugin.update_port(admin_context, port_id, subport)"},{"line_number":590,"context_line":"            except (os_db_exc.DBReferenceError, n_exc.PortNotFound):"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f436f4f_9fdf71d5","line":587,"in_reply_to":"9f436f4f_1fea61ab","updated":"2017-08-10 12:33:02.000000000","message":"\" so I think it\u0027s best to call it anyways.\" - I am fine with this approach","commit_id":"475a7b69eb2382a4667e6b58a795a796174482da"},{"author":{"_account_id":23804,"name":"Daniel Alvarez","email":"dalvarez@redhat.com","username":"dalvarez"},"change_message_id":"157b6021863f790988ef6bb72ed9b375324e49b7","unresolved":false,"context_lines":[{"line_number":584,"context_line":"            try:"},{"line_number":585,"context_line":"                port \u003d self._plugin.get_port(admin_context, parent_port)"},{"line_number":586,"context_line":"                host_id \u003d port.get(portbindings.HOST_ID, \u0027\u0027)"},{"line_number":587,"context_line":"                subport \u003d {\u0027id\u0027: port_id,"},{"line_number":588,"context_line":"                           \u0027port\u0027: {\u0027binding:host_id\u0027: host_id}}"},{"line_number":589,"context_line":"                self._plugin.update_port(admin_context, port_id, subport)"},{"line_number":590,"context_line":"            except (os_db_exc.DBReferenceError, n_exc.PortNotFound):"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f436f4f_1fea61ab","line":587,"in_reply_to":"9f436f4f_7ca17ba9","updated":"2017-08-10 12:28:06.000000000","message":"Yes, i think it makes sense to call it only if host_id is not None/\u0027\u0027. However, I think we always want to call update_port otherwise because if host is already set in the subport and it changed for the parent, we want it to update the subport. I could try not to update it if it has no changed but I would also need to call the plugin to retrieve its details so I think it\u0027s best to call it anyways.","commit_id":"475a7b69eb2382a4667e6b58a795a796174482da"}],"networking_ovn/ml2/trunk_driver.py":[{"author":{"_account_id":23567,"name":"Luis Tomas Bolivar","email":"ltomasbo@redhat.com","username":"ltomasbo"},"change_message_id":"00e5ed7f7c133d8e24ea098f38d0eed698ddd63f","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        if parent_port and tag:"},{"line_number":48,"context_line":"            binding_profile \u003d {\u0027parent_name\u0027: parent_port, \u0027tag\u0027: tag}"},{"line_number":49,"context_line":"        port \u003d {\u0027id\u0027: port_id, \u0027port\u0027: {\u0027binding:profile\u0027: binding_profile}}"},{"line_number":50,"context_line":"        try:"},{"line_number":51,"context_line":"            self.plugin_driver._plugin.update_port(context, port_id, port)"},{"line_number":52,"context_line":"        except (os_db_exc.DBReferenceError, n_exc.PortNotFound):"},{"line_number":53,"context_line":"            LOG.debug(\"Port not found trying to set binding_profile: %s\","},{"line_number":54,"context_line":"                      port_id)"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"    def _set_sub_ports(self, parent_port, subports):"},{"line_number":57,"context_line":"        _nb_ovn \u003d self.plugin_driver._nb_ovn"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff346bd7_4e755df9","line":54,"range":{"start_line":50,"start_character":0,"end_line":54,"end_character":30},"updated":"2017-07-28 11:41:31.000000000","message":"Should other exceptions be captured here? When a failure setting the binding profile should stop doing the set_sub_port/unset_sub_port and when it shouldn\u0027t?","commit_id":"30115d63fb372bb570c1226cd8676975a6d8eafd"},{"author":{"_account_id":23804,"name":"Daniel Alvarez","email":"dalvarez@redhat.com","username":"dalvarez"},"change_message_id":"b1a202dc23f5a031487f55cebc7ece1384f947cc","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        if parent_port and tag:"},{"line_number":48,"context_line":"            binding_profile \u003d {\u0027parent_name\u0027: parent_port, \u0027tag\u0027: tag}"},{"line_number":49,"context_line":"        port \u003d {\u0027id\u0027: port_id, \u0027port\u0027: {\u0027binding:profile\u0027: binding_profile}}"},{"line_number":50,"context_line":"        try:"},{"line_number":51,"context_line":"            self.plugin_driver._plugin.update_port(context, port_id, port)"},{"line_number":52,"context_line":"        except (os_db_exc.DBReferenceError, n_exc.PortNotFound):"},{"line_number":53,"context_line":"            LOG.debug(\"Port not found trying to set binding_profile: %s\","},{"line_number":54,"context_line":"                      port_id)"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"    def _set_sub_ports(self, parent_port, subports):"},{"line_number":57,"context_line":"        _nb_ovn \u003d self.plugin_driver._nb_ovn"}],"source_content_type":"text/x-python","patch_set":1,"id":"df3967d1_e66a287f","line":54,"range":{"start_line":50,"start_character":0,"end_line":54,"end_character":30},"in_reply_to":"ff346bd7_4e755df9","updated":"2017-08-03 15:04:06.000000000","message":"We probably want to bubble all exceptions up and let caller retry just in case but not complete the transaction to NB database if this failed because it won\u0027t transition to ACTIVE","commit_id":"30115d63fb372bb570c1226cd8676975a6d8eafd"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"5bef09788b0b9b28880e04b9ba4420d5f611e0e9","unresolved":false,"context_lines":[{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    def _set_binding_profile(self, port_id, parent_port, tag\u003dNone):"},{"line_number":45,"context_line":"        context \u003d n_context.get_admin_context()"},{"line_number":46,"context_line":"        binding_profile \u003d {}"},{"line_number":47,"context_line":"        if parent_port and tag:"},{"line_number":48,"context_line":"            binding_profile \u003d {\u0027parent_name\u0027: parent_port, \u0027tag\u0027: tag}"},{"line_number":49,"context_line":"        port \u003d {\u0027id\u0027: port_id, \u0027port\u0027: {\u0027binding:profile\u0027: binding_profile}}"}],"source_content_type":"text/x-python","patch_set":3,"id":"bf3e73b7_bd64b6ba","line":46,"updated":"2017-08-07 09:54:12.000000000","message":"I would deprecate this if we can and make the code in ovn_client.py reading this to obey the new neutron models for subport (while still supporting this old way), or otherwise we can document here why do we mark this in the binding profile as it\u0027s not obvious if you\u0027re new to it.","commit_id":"122d12e900a1c39ef9fd9d1ac9a72314fcf3d027"},{"author":{"_account_id":23804,"name":"Daniel Alvarez","email":"dalvarez@redhat.com","username":"dalvarez"},"change_message_id":"2dd26d1a02c3aa70f55f146b0c79c60381103783","unresolved":false,"context_lines":[{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    def _set_binding_profile(self, port_id, parent_port, tag\u003dNone):"},{"line_number":45,"context_line":"        context \u003d n_context.get_admin_context()"},{"line_number":46,"context_line":"        binding_profile \u003d {}"},{"line_number":47,"context_line":"        if parent_port and tag:"},{"line_number":48,"context_line":"            binding_profile \u003d {\u0027parent_name\u0027: parent_port, \u0027tag\u0027: tag}"},{"line_number":49,"context_line":"        port \u003d {\u0027id\u0027: port_id, \u0027port\u0027: {\u0027binding:profile\u0027: binding_profile}}"}],"source_content_type":"text/x-python","patch_set":3,"id":"bf3e73b7_3de32608","line":46,"in_reply_to":"bf3e73b7_bd64b6ba","updated":"2017-08-07 09:57:07.000000000","message":"Yeah, i\u0027d deprecate [0] but I think there\u0027re good reasons for us to keep it. Let\u0027s wait for Russel to clarify :)\n[0] https://github.com/openstack/networking-ovn/blob/c8097ca3259613fdfc7c8fd171ad9b9950f58f97/doc/source/admin/containers.rst","commit_id":"122d12e900a1c39ef9fd9d1ac9a72314fcf3d027"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"ac3c536a25b95cb4839ed550ca90b024949a90f2","unresolved":false,"context_lines":[{"line_number":46,"context_line":"        binding_profile \u003d {}"},{"line_number":47,"context_line":"        if parent_port and tag:"},{"line_number":48,"context_line":"            binding_profile \u003d {\u0027parent_name\u0027: parent_port, \u0027tag\u0027: tag}"},{"line_number":49,"context_line":"        port \u003d {\u0027id\u0027: port_id, \u0027port\u0027: {\u0027binding:profile\u0027: binding_profile}}"},{"line_number":50,"context_line":"        try:"},{"line_number":51,"context_line":"            self.plugin_driver._plugin.update_port(context, port_id, port)"},{"line_number":52,"context_line":"        except (os_db_exc.DBReferenceError, n_exc.PortNotFound):"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f436f4f_bcac838c","line":49,"updated":"2017-08-10 11:58:29.000000000","message":"Do we need to change \u0027id\u0027 also?","commit_id":"475a7b69eb2382a4667e6b58a795a796174482da"},{"author":{"_account_id":23804,"name":"Daniel Alvarez","email":"dalvarez@redhat.com","username":"dalvarez"},"change_message_id":"157b6021863f790988ef6bb72ed9b375324e49b7","unresolved":false,"context_lines":[{"line_number":46,"context_line":"        binding_profile \u003d {}"},{"line_number":47,"context_line":"        if parent_port and tag:"},{"line_number":48,"context_line":"            binding_profile \u003d {\u0027parent_name\u0027: parent_port, \u0027tag\u0027: tag}"},{"line_number":49,"context_line":"        port \u003d {\u0027id\u0027: port_id, \u0027port\u0027: {\u0027binding:profile\u0027: binding_profile}}"},{"line_number":50,"context_line":"        try:"},{"line_number":51,"context_line":"            self.plugin_driver._plugin.update_port(context, port_id, port)"},{"line_number":52,"context_line":"        except (os_db_exc.DBReferenceError, n_exc.PortNotFound):"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f436f4f_dff4d989","line":49,"in_reply_to":"9f436f4f_bcac838c","updated":"2017-08-10 12:28:06.000000000","message":"Hmmm, right we don\u0027t!","commit_id":"475a7b69eb2382a4667e6b58a795a796174482da"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"ac3c536a25b95cb4839ed550ca90b024949a90f2","unresolved":false,"context_lines":[{"line_number":67,"context_line":"        _nb_ovn \u003d self.plugin_driver._nb_ovn"},{"line_number":68,"context_line":"        with _nb_ovn.transaction(check_error\u003dTrue) as txn:"},{"line_number":69,"context_line":"            for port in subports:"},{"line_number":70,"context_line":"                self._set_binding_profile(port.port_id, None)"},{"line_number":71,"context_line":"                txn.add(_nb_ovn.set_lswitch_port(port.port_id,"},{"line_number":72,"context_line":"                                                 parent_name\u003d[],"},{"line_number":73,"context_line":"                                                 tag\u003d[]))"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f436f4f_3c353347","line":70,"updated":"2017-08-10 11:58:29.000000000","message":"Are we trying to clear binding_profile here?","commit_id":"475a7b69eb2382a4667e6b58a795a796174482da"},{"author":{"_account_id":23804,"name":"Daniel Alvarez","email":"dalvarez@redhat.com","username":"dalvarez"},"change_message_id":"157b6021863f790988ef6bb72ed9b375324e49b7","unresolved":false,"context_lines":[{"line_number":67,"context_line":"        _nb_ovn \u003d self.plugin_driver._nb_ovn"},{"line_number":68,"context_line":"        with _nb_ovn.transaction(check_error\u003dTrue) as txn:"},{"line_number":69,"context_line":"            for port in subports:"},{"line_number":70,"context_line":"                self._set_binding_profile(port.port_id, None)"},{"line_number":71,"context_line":"                txn.add(_nb_ovn.set_lswitch_port(port.port_id,"},{"line_number":72,"context_line":"                                                 parent_name\u003d[],"},{"line_number":73,"context_line":"                                                 tag\u003d[]))"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f436f4f_7f2badea","line":70,"in_reply_to":"9f436f4f_3c353347","updated":"2017-08-10 12:28:06.000000000","message":"Yes, that was my intent","commit_id":"475a7b69eb2382a4667e6b58a795a796174482da"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"ae1fa55a11b3a0781c3d14f40237f3fd6ded08b3","unresolved":false,"context_lines":[{"line_number":67,"context_line":"        _nb_ovn \u003d self.plugin_driver._nb_ovn"},{"line_number":68,"context_line":"        with _nb_ovn.transaction(check_error\u003dTrue) as txn:"},{"line_number":69,"context_line":"            for port in subports:"},{"line_number":70,"context_line":"                self._set_binding_profile(port.port_id, None)"},{"line_number":71,"context_line":"                txn.add(_nb_ovn.set_lswitch_port(port.port_id,"},{"line_number":72,"context_line":"                                                 parent_name\u003d[],"},{"line_number":73,"context_line":"                                                 tag\u003d[]))"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f436f4f_1fa2614c","line":70,"in_reply_to":"9f436f4f_7f2badea","updated":"2017-08-10 12:33:02.000000000","message":"thanks","commit_id":"475a7b69eb2382a4667e6b58a795a796174482da"}]}
