)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":11307,"name":"Andreas Scheuring","email":"andreas.scheuring@de.ibm.com","username":"uniqueName"},"change_message_id":"b8355361b417761010578f85b17faddb36a17eec","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"set vif_type in db to distributed for dvr port"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"In next patch, to make dvr port binding generic, we will use vif_type"},{"line_number":10,"context_line":"instead of device_owner for identifying and processing distributed ports."},{"line_number":11,"context_line":"Current implementation, to identify and process these ports, is using"},{"line_number":12,"context_line":"device_owner from both port_dict and ports table entry."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"1aa78d24_6750760b","line":9,"range":{"start_line":9,"start_character":0,"end_line":9,"end_character":13},"updated":"2016-07-11 07:48:41.000000000","message":"Why not first describing the current change and then talk about what will happen in the next patchset? \nIf I get it right, lines 16-22 relate to this patchset, while lines 9-14 explain a follow on patchset.","commit_id":"984782461ee7ed3417f93dbe0e2273685bd359eb"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"ceb5f3b2b496090b50de4a25b12831ea634ee18d","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"set vif_type in db to distributed for dvr port"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"In next patch, to make dvr port binding generic, we will use vif_type"},{"line_number":10,"context_line":"instead of device_owner for identifying and processing distributed ports."},{"line_number":11,"context_line":"Current implementation, to identify and process these ports, is using"},{"line_number":12,"context_line":"device_owner from both port_dict and ports table entry."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"1aa78d24_21277613","line":9,"range":{"start_line":9,"start_character":0,"end_line":9,"end_character":13},"in_reply_to":"1aa78d24_21d2d600","updated":"2016-07-11 09:51:57.000000000","message":"sure, I will try :)","commit_id":"984782461ee7ed3417f93dbe0e2273685bd359eb"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"8f5e5893f3777d28f214ec36c12ff5944e096e54","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"set vif_type in db to distributed for dvr port"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"In next patch, to make dvr port binding generic, we will use vif_type"},{"line_number":10,"context_line":"instead of device_owner for identifying and processing distributed ports."},{"line_number":11,"context_line":"Current implementation, to identify and process these ports, is using"},{"line_number":12,"context_line":"device_owner from both port_dict and ports table entry."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"1aa78d24_eaf38b9d","line":9,"range":{"start_line":9,"start_character":0,"end_line":9,"end_character":13},"in_reply_to":"1aa78d24_6750760b","updated":"2016-07-11 08:26:17.000000000","message":"In lines 9-22, I am explaining why we need this patch. If I just explain what I am doing in this patch, then reviewers won\u0027t understand why it is needed and may ask for reason for this patch.\n\nSo I am explaining why this patch is needed and what the patch does can be understood with title of the commit message itself.","commit_id":"984782461ee7ed3417f93dbe0e2273685bd359eb"},{"author":{"_account_id":11307,"name":"Andreas Scheuring","email":"andreas.scheuring@de.ibm.com","username":"uniqueName"},"change_message_id":"3d68fce96fc542a8cffb23eda81b59de2f7a2af1","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"set vif_type in db to distributed for dvr port"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"In next patch, to make dvr port binding generic, we will use vif_type"},{"line_number":10,"context_line":"instead of device_owner for identifying and processing distributed ports."},{"line_number":11,"context_line":"Current implementation, to identify and process these ports, is using"},{"line_number":12,"context_line":"device_owner from both port_dict and ports table entry."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"1aa78d24_21d2d600","line":9,"range":{"start_line":9,"start_character":0,"end_line":9,"end_character":13},"in_reply_to":"1aa78d24_eaf38b9d","updated":"2016-07-11 09:50:56.000000000","message":"agree. you need to do both. My point was just, first describe what this patch is doing, and then elaborate about context. As a reviewer I primarily would like to understand what this patch is doing. IMO :)","commit_id":"984782461ee7ed3417f93dbe0e2273685bd359eb"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"4b7336317976e8a9505b0d2888f2b8a7d6bd8c33","unresolved":false,"context_lines":[{"line_number":18,"context_line":"For DVR port binding, current implementation to identify and process"},{"line_number":19,"context_line":"dvr ports, uses device_owner from both port_dict and ports table entry."},{"line_number":20,"context_line":"In next patch, we use vif_type(from both port_dict and ml2_port_bindings"},{"line_number":21,"context_line":"table) instead of device_owner."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Note: Mechanism drivers will set the actual vif type(for example,"},{"line_number":24,"context_line":"\u0027ovs\u0027) in \u0027ml2_distributed_port_bindings\u0027 during dvr port binding."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"1aa78d24_f9145a4e","line":21,"updated":"2016-07-13 22:46:31.000000000","message":"Will there be any advantage of using the \u0027vif_type\u0027 rather then the device_owner.\nI would recommend that we do not deviate too much and make any changes unportable to older versions by fixing this.","commit_id":"abbaa16f45fa3c4ce3ae260dfffd12dc5fdeffaa"},{"author":{"_account_id":7016,"name":"Swaminathan Vasudevan","email":"swvasude@cisco.com","username":"souminathan"},"change_message_id":"c3c90a76a0030273238ac0e22497d83f3f355bd3","unresolved":false,"context_lines":[{"line_number":18,"context_line":"For DVR port binding, current implementation to identify and process"},{"line_number":19,"context_line":"dvr ports, uses device_owner from both port_dict and ports table entry."},{"line_number":20,"context_line":"In next patch, we use vif_type(from both port_dict and ml2_port_bindings"},{"line_number":21,"context_line":"table) instead of device_owner."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Note: Mechanism drivers will set the actual vif type(for example,"},{"line_number":24,"context_line":"\u0027ovs\u0027) in \u0027ml2_distributed_port_bindings\u0027 during dvr port binding."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"1aa78d24_f449d333","line":21,"in_reply_to":"1aa78d24_c98ee6cf","updated":"2016-07-14 18:11:11.000000000","message":"My only concern with these changes are the issues with backporting.","commit_id":"abbaa16f45fa3c4ce3ae260dfffd12dc5fdeffaa"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"25bdfda29eb85718a653e3c5e074d00f77014137","unresolved":false,"context_lines":[{"line_number":18,"context_line":"For DVR port binding, current implementation to identify and process"},{"line_number":19,"context_line":"dvr ports, uses device_owner from both port_dict and ports table entry."},{"line_number":20,"context_line":"In next patch, we use vif_type(from both port_dict and ml2_port_bindings"},{"line_number":21,"context_line":"table) instead of device_owner."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Note: Mechanism drivers will set the actual vif type(for example,"},{"line_number":24,"context_line":"\u0027ovs\u0027) in \u0027ml2_distributed_port_bindings\u0027 during dvr port binding."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"dada55a8_ea103e5b","line":21,"in_reply_to":"1aa78d24_f449d333","updated":"2016-07-27 08:13:51.000000000","message":"It\u0027s the same discussion we always have around refactors, shall we break backports (make them more difficult) or shall we live with technical debt forever?.\n\nIMHO fixing technical debt specially when it\u0027s related to make features more interoperable it\u0027s really worth, and while it adds some extra pain in the face of backporting patches, we should do it.","commit_id":"abbaa16f45fa3c4ce3ae260dfffd12dc5fdeffaa"},{"author":{"_account_id":10267,"name":"venkata anil","email":"anilvenkata@redhat.com","username":"anil"},"change_message_id":"85a8aee1f2d10ea735a28baf92ac0f87f06c451c","unresolved":false,"context_lines":[{"line_number":18,"context_line":"For DVR port binding, current implementation to identify and process"},{"line_number":19,"context_line":"dvr ports, uses device_owner from both port_dict and ports table entry."},{"line_number":20,"context_line":"In next patch, we use vif_type(from both port_dict and ml2_port_bindings"},{"line_number":21,"context_line":"table) instead of device_owner."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Note: Mechanism drivers will set the actual vif type(for example,"},{"line_number":24,"context_line":"\u0027ovs\u0027) in \u0027ml2_distributed_port_bindings\u0027 during dvr port binding."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"1aa78d24_c98ee6cf","line":21,"in_reply_to":"1aa78d24_f9145a4e","updated":"2016-07-14 05:05:10.000000000","message":"using the \u0027vif_type\u0027 rather then the device_owner is needed for HA portbinding. With this HA will also set vif_type to distributed and use existing DVR portbinding i.e existing portbinding will be generic and will be used for all DVR, HA and HA+DVR cases.\n\nPatch for HA to use DVR portbinding\nhttps://review.openstack.org/#/c/323314/\n\nI can\u0027t use device_owner as I explained in my previous comment(main reason is - port with DEVICE_OWNER_ROUTER_SNAT is a distributed port when router is HA + DVR and not a distributed port when router is only DVR. SO device_owner is not useful for this port\u0027s binding)\n\nCopying my previous comments here - \n\nWhy I am using vif_type instead of device_owner?\n\nThese are the distributed router ports\n\n1) port with device owner DEVICE_OWNER_DVR_INTERFACE - when a router is only DVR\n2) port with device owner DEVICE_OWNER_HA_REPLICATED_INT - when a router is only HA\n3) ports with device owner DEVICE_OWNER_DVR_INTERFACE,  DEVICE_OWNER_ROUTER_SNAT - when a router is HA + DVR\n\nSo port with DEVICE_OWNER_ROUTER_SNAT is a distributed port when router is HA + DVR and not a distributed port when router is only DVR.\n\nSo I can\u0027t rely only device_owner and instead set vif_type based on device_owner and some other parameters i.e https://review.openstack.org/#/c/323314/12/neutron/plugins/ml2/plugin.py L333\n\nThere are two reasons for using vif_type\n\n1) As you see we check for device_owner at many places in the code. If we are replacing that with the method[1], unnecessarily we are introducing a method call at all these places, which can be avoided with simple vif_type check. Making this function generic and accessible from all the places(l2 plugin, l3 plugin, l2pop driver, l3 rpc api and rpc handlers, etc) in the code is also not easy. One more thing is, every time this method is called, there is a DB access. So I feel checking for vif_type is simple.\n\n\n2) If you see, dvr ports are already setting vif_type to distributed as part of port_dict. That means wherever port_dict is used in the code(and also user api requests) they are using vif_type as distributed.  I don\u0027t know why they are not doing that in ml2_port_bindings table. It might be a bug. If this change is not done then\n1) vif_type shown to users through api will be distributed\n2) vif_type in ml2_port_bindings will be unbound(and never used anywhere in the code)\n3) vif_type in ml2_distributed_port_bindings can be unbound, failed or mechanism specific vif_type(like ovs).\nAt least I am avoiding inconsistency between what user sees as part of API and what is in ml2_port_bindings. With vif_type\u003ddistributed in ml2_port_bindings, this table shows that it is a distributed port and actual binding of the table will be available in ml2_distributed_port_bindings table.\n\n[1] https://review.openstack.org/#/c/323314/12/neutron/plugins/ml2/plugin.py L333","commit_id":"abbaa16f45fa3c4ce3ae260dfffd12dc5fdeffaa"}]}
