)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e1ac79d4210f9dd681589ee2a4f6d26da89d8bbe","unresolved":false,"context_lines":[{"line_number":9,"context_line":"Removal of empty bridges have been disabled to fix a race condition"},{"line_number":10,"context_line":"between Nova and Neutron where a bridge would be removed if"},{"line_number":11,"context_line":"the only instance using it is rebooted. This means empty bridges"},{"line_number":12,"context_line":"will pill up over time."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"This script can be used to periodically remove empty bridges by running it"},{"line_number":15,"context_line":"on compute nodes."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"da20952f_6938513e","line":12,"updated":"2015-09-08 23:35:46.000000000","message":"s/pill/pile/","commit_id":"cc36d95688d787443bffe413ff5c58eec20ba6b9"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"0e852ae01b779fdf5049f5655adcae44fa13f939","unresolved":false,"context_lines":[{"line_number":9,"context_line":"Removal of empty bridges have been disabled to fix a race condition"},{"line_number":10,"context_line":"between Nova and Neutron where a bridge would be removed if"},{"line_number":11,"context_line":"the only instance using it is rebooted. This means empty bridges"},{"line_number":12,"context_line":"will pill up over time."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"This script can be used to periodically remove empty bridges by running it"},{"line_number":15,"context_line":"on compute nodes."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"da20952f_e48ec8cf","line":12,"in_reply_to":"da20952f_6938513e","updated":"2015-09-09 00:28:12.000000000","message":"Done","commit_id":"cc36d95688d787443bffe413ff5c58eec20ba6b9"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"f4b0647369c5197bd2f39c981482fde29aae8811","unresolved":false,"context_lines":[{"line_number":12,"context_line":"will pile up over time."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"This script can be used to periodically remove empty bridges by running it"},{"line_number":15,"context_line":"on compute nodes."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Change-Id: Ieb2796381579ad295abf361ce483d979a53d2bd6"},{"line_number":18,"context_line":"Related-bug: #1328546"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"da20952f_efbe78ff","line":15,"updated":"2015-09-09 19:49:35.000000000","message":"imo, a DocImpact tag is required","commit_id":"f900a91aab6e79bd9561600fca917504ce266edf"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"3fbf1697a41dbf1e6075c9b57d0c853e70c5e8c5","unresolved":false,"context_lines":[{"line_number":12,"context_line":"will pile up over time."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"This script can be used to periodically remove empty bridges by running it"},{"line_number":15,"context_line":"on compute nodes."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Change-Id: Ieb2796381579ad295abf361ce483d979a53d2bd6"},{"line_number":18,"context_line":"Related-bug: #1328546"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"da20952f_2fd310d7","line":15,"in_reply_to":"da20952f_efbe78ff","updated":"2015-09-09 20:07:54.000000000","message":"Done","commit_id":"f900a91aab6e79bd9561600fca917504ce266edf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e2e8608d44e7a143bd664f60b3c66bd7c4a0892c","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add neutron-linuxbridge-cleanup util"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Removal of empty bridges have been disabled to fix a race condition"},{"line_number":10,"context_line":"between Nova and Neutron where a bridge would be removed if"},{"line_number":11,"context_line":"the only instance using it is rebooted. This means empty bridges"},{"line_number":12,"context_line":"will pile up over time."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"da20952f_5d604b35","line":9,"updated":"2015-09-10 23:54:17.000000000","message":"You might want to call out 8dd8a7d93564168b98fa2350eedf56acede42b0f  for reference.","commit_id":"0f23dea3c4a328843345583fb8bf10b034d664b1"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"2ff30d2ee16e74d3406bfdc29c6d06d2f55c7b97","unresolved":false,"context_lines":[{"line_number":21,"context_line":"DocImpact: Add neutron-linuxbridge-cleanup util"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Change-Id: Ieb2796381579ad295abf361ce483d979a53d2bd6"},{"line_number":24,"context_line":"Related-bug: #1328546"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"da20952f_46b09c8b","line":24,"updated":"2015-09-10 09:11:06.000000000","message":"It also deserves its own bug","commit_id":"0f23dea3c4a328843345583fb8bf10b034d664b1"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e2e8608d44e7a143bd664f60b3c66bd7c4a0892c","unresolved":false,"context_lines":[{"line_number":21,"context_line":"DocImpact: Add neutron-linuxbridge-cleanup util"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Change-Id: Ieb2796381579ad295abf361ce483d979a53d2bd6"},{"line_number":24,"context_line":"Related-bug: #1328546"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"da20952f_7d650f43","line":24,"in_reply_to":"da20952f_46b09c8b","updated":"2015-09-10 23:54:17.000000000","message":"I\u0027m not sure what purpose a new bug would serve given this is directly related to commit 8dd8a7d93564168b98fa2350eedf56acede42b0f removing the code that automatically removed empty bridges.\n\nI guess the bug would be that empty bridges can pile up over time and this would provide a tool to remove them, since we don\u0027t want a periodic task doing that since it would still be racy.","commit_id":"0f23dea3c4a328843345583fb8bf10b034d664b1"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"99449c502e94500f3e4a6dc365acacd5984293f8","unresolved":false,"context_lines":[{"line_number":23,"context_line":"DocImpact: Add neutron-linuxbridge-cleanup util"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"Change-Id: Ieb2796381579ad295abf361ce483d979a53d2bd6"},{"line_number":26,"context_line":"Related-bug: #1328546"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"ba15a1d1_2bec0ef2","line":26,"updated":"2015-09-17 04:28:49.000000000","message":"as suggested in earlier PS, a separate bug is better for tracking purpose.","commit_id":"61c28fdf31d5e8a0ff38077a4b5e97634c0f3d28"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"0cb0070d09f2f0ec370a242e07b4fa97affe1c49","unresolved":false,"context_lines":[{"line_number":23,"context_line":"DocImpact: Add neutron-linuxbridge-cleanup util"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"Change-Id: Ieb2796381579ad295abf361ce483d979a53d2bd6"},{"line_number":26,"context_line":"Related-bug: #1328546"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"ba15a1d1_7c313f59","line":26,"in_reply_to":"ba15a1d1_11b58c7c","updated":"2015-09-17 21:57:49.000000000","message":"Done. I hope people will open technical debt bugs in the future so we can better track them.","commit_id":"61c28fdf31d5e8a0ff38077a4b5e97634c0f3d28"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e73d62f2b9fdf477bf1d3f0c1f4d84e3f21dc1b1","unresolved":false,"context_lines":[{"line_number":23,"context_line":"DocImpact: Add neutron-linuxbridge-cleanup util"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"Change-Id: Ieb2796381579ad295abf361ce483d979a53d2bd6"},{"line_number":26,"context_line":"Related-bug: #1328546"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"ba15a1d1_f1c81857","line":26,"in_reply_to":"ba15a1d1_2bec0ef2","updated":"2015-09-17 21:06:30.000000000","message":"This script is a direct relation to the bug above, what is the point in opening a new bug for this?  In that bug, the automatic empty bridge cleanup was removed, which means you have to manually remove those.  This doesn\u0027t close bug 1328546 but it\u0027s obviously related.  Any new bug would just say bug 1328546 leaves old empty bridges around and we should provide a tool to remove them, so it seems like busy work.","commit_id":"61c28fdf31d5e8a0ff38077a4b5e97634c0f3d28"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"8c438890eb5f32389faee4410a9bfabba8cd00e1","unresolved":false,"context_lines":[{"line_number":23,"context_line":"DocImpact: Add neutron-linuxbridge-cleanup util"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"Change-Id: Ieb2796381579ad295abf361ce483d979a53d2bd6"},{"line_number":26,"context_line":"Related-bug: #1328546"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"ba15a1d1_11b58c7c","line":26,"in_reply_to":"ba15a1d1_f1c81857","updated":"2015-09-17 21:17:35.000000000","message":"Ideally such bug should have been created by the one fixing related bug as a tech debt bug.","commit_id":"61c28fdf31d5e8a0ff38077a4b5e97634c0f3d28"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"915f27959f615abe79c197573fd4afa41d10ce4c","unresolved":false,"context_lines":[{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Note: Usage of this script can still trigger the original race condition."},{"line_number":18,"context_line":"It should be used when you don\u0027t expect anyone do be doing operations"},{"line_number":19,"context_line":"on their instances."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"[1] Commit 8dd8a7d93564168b98fa2350eedf56acede42b0f"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":18,"id":"9a1a9d01_45e05f29","line":19,"updated":"2015-09-29 11:39:38.000000000","message":"this is kind of dodgy and really defeats the purpose in my opinion. why not have a common lock that is shared between nova and neutron. that is, we both use lock utils today. so why not make sure that an external lock is used witht he same name - then we should not have the race","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"},{"author":{"_account_id":11682,"name":"Ryan Moats","email":"rmoats@us.ibm.com","username":"regXboi"},"change_message_id":"9baecf132202d2c4ccaabaf3e0bf90eff41f69ac","unresolved":false,"context_lines":[{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Note: Usage of this script can still trigger the original race condition."},{"line_number":18,"context_line":"It should be used when you don\u0027t expect anyone do be doing operations"},{"line_number":19,"context_line":"on their instances."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"[1] Commit 8dd8a7d93564168b98fa2350eedf56acede42b0f"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":18,"id":"9a1a9d01_acea7672","line":19,"in_reply_to":"9a1a9d01_45e05f29","updated":"2015-09-29 16:32:07.000000000","message":"That would be a much bigger change and while it might be possible, I\u0027d prefer to have this in hand while that change is being worked.","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"},{"author":{"_account_id":4187,"name":"Ryan Tidwell","email":"rtidwell@suse.com","username":"ryan-tidwell"},"change_message_id":"310f8b593e1807e2aed8fbd96b3ab553aec39893","unresolved":false,"context_lines":[{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Note: Usage of this script can still trigger the original race condition."},{"line_number":18,"context_line":"It should be used when you don\u0027t expect anyone do be doing operations"},{"line_number":19,"context_line":"on their instances."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"[1] Commit 8dd8a7d93564168b98fa2350eedf56acede42b0f"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":18,"id":"9a1a9d01_88995a7b","line":19,"in_reply_to":"9a1a9d01_acea7672","updated":"2015-09-30 22:42:31.000000000","message":"I agree with @Ryan, this is a handy tool to have in the toolbox while a better solution is being ironed out.","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"3c84d019e15f17db8ef6c905bb0e804dd8dfb454","unresolved":false,"context_lines":[{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Note: Usage of this script can still trigger the original race condition."},{"line_number":18,"context_line":"It should be used when you don\u0027t expect anyone do be doing operations"},{"line_number":19,"context_line":"on their instances."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"[1] Commit 8dd8a7d93564168b98fa2350eedf56acede42b0f"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":18,"id":"9a1a9d01_8972f70f","line":19,"in_reply_to":"9a1a9d01_acea7672","updated":"2015-10-01 19:50:48.000000000","message":"I agree with Ryans! :)","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"}],"neutron/cmd/linuxbridge_cleanup.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e1ac79d4210f9dd681589ee2a4f6d26da89d8bbe","unresolved":false,"context_lines":[{"line_number":1,"context_line":"import sys"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"from oslo_config import cfg"},{"line_number":4,"context_line":"from oslo_log import log as logging"}],"source_content_type":"text/x-python","patch_set":1,"id":"da20952f_e94461b8","line":1,"updated":"2015-09-08 23:35:46.000000000","message":"I\u0027m assuming you might want a copyright header here?","commit_id":"cc36d95688d787443bffe413ff5c58eec20ba6b9"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"0e852ae01b779fdf5049f5655adcae44fa13f939","unresolved":false,"context_lines":[{"line_number":1,"context_line":"import sys"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"from oslo_config import cfg"},{"line_number":4,"context_line":"from oslo_log import log as logging"}],"source_content_type":"text/x-python","patch_set":1,"id":"da20952f_84ba6c70","line":1,"in_reply_to":"da20952f_e94461b8","updated":"2015-09-09 00:28:12.000000000","message":"Done","commit_id":"cc36d95688d787443bffe413ff5c58eec20ba6b9"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"f4b0647369c5197bd2f39c981482fde29aae8811","unresolved":false,"context_lines":[{"line_number":33,"context_line":"    return conf"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"def remove_empty_bridges(conf):"},{"line_number":37,"context_line":"    try:"},{"line_number":38,"context_line":"        interface_mappings \u003d q_utils.parse_mappings("},{"line_number":39,"context_line":"            conf.LINUX_BRIDGE.physical_interface_mappings)"}],"source_content_type":"text/x-python","patch_set":3,"id":"da20952f_0f572ccb","line":36,"updated":"2015-09-09 19:49:35.000000000","message":"imo, this script must be tested with a functional test","commit_id":"f900a91aab6e79bd9561600fca917504ce266edf"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"3fbf1697a41dbf1e6075c9b57d0c853e70c5e8c5","unresolved":false,"context_lines":[{"line_number":33,"context_line":"    return conf"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"def remove_empty_bridges(conf):"},{"line_number":37,"context_line":"    try:"},{"line_number":38,"context_line":"        interface_mappings \u003d q_utils.parse_mappings("},{"line_number":39,"context_line":"            conf.LINUX_BRIDGE.physical_interface_mappings)"}],"source_content_type":"text/x-python","patch_set":3,"id":"da20952f_2fa1d046","line":36,"in_reply_to":"da20952f_0f572ccb","updated":"2015-09-09 20:07:54.000000000","message":"Sorry, this won\u0027t happen. I just don\u0027t have the bandwidth to make that happen. If someone else can write it, I\u0027m ok with that.","commit_id":"f900a91aab6e79bd9561600fca917504ce266edf"},{"author":{"_account_id":13252,"name":"Dr. Jens Harbott","display_name":"Jens Harbott (frickler)","email":"frickler@offenerstapel.de","username":"jrosenboom"},"change_message_id":"27bcab7a2345717ecd8ebc7568cc4d6183cda7f3","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        sys.exit(1)"},{"line_number":43,"context_line":"    LOG.info(_LI(\"Interface mappings: %s\"), interface_mappings)"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("},{"line_number":46,"context_line":"        interface_mappings)"},{"line_number":47,"context_line":"    LOG.info(_LI(\"Agent initialized successfully, now running... \"))"},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"da20952f_126459e3","line":45,"updated":"2015-09-09 05:22:00.000000000","message":"The signature of LinuxBridgeManager has been changed in Ia0eaa6233d8da93da32e86404b15184b77937d0a, you also need to give bridge_mappings as parameter.","commit_id":"f900a91aab6e79bd9561600fca917504ce266edf"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"3fbf1697a41dbf1e6075c9b57d0c853e70c5e8c5","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        sys.exit(1)"},{"line_number":43,"context_line":"    LOG.info(_LI(\"Interface mappings: %s\"), interface_mappings)"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("},{"line_number":46,"context_line":"        interface_mappings)"},{"line_number":47,"context_line":"    LOG.info(_LI(\"Agent initialized successfully, now running... \"))"},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"da20952f_cf8854c9","line":45,"in_reply_to":"da20952f_126459e3","updated":"2015-09-09 20:07:54.000000000","message":"Done","commit_id":"f900a91aab6e79bd9561600fca917504ce266edf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"28c710799ee9b55b59ad5fbe8aeb1951b85d1402","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        sys.exit(1)"},{"line_number":43,"context_line":"    LOG.info(_LI(\"Interface mappings: %s\"), interface_mappings)"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("},{"line_number":46,"context_line":"        interface_mappings)"},{"line_number":47,"context_line":"    LOG.info(_LI(\"Agent initialized successfully, now running... \"))"},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"da20952f_966602ba","line":45,"in_reply_to":"da20952f_126459e3","updated":"2015-09-09 16:33:18.000000000","message":"Yeah, that\u0027s why pylint is failing:\n\nhttp://logs.openstack.org/08/221508/3/check/gate-neutron-pep8/f22bd4c/console.html#_2015-09-09_00_32_34_519","commit_id":"f900a91aab6e79bd9561600fca917504ce266edf"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"43348e8957fac3326a9f1bc7c8eab9ef95fc116f","unresolved":false,"context_lines":[{"line_number":19,"context_line":"from neutron.common import utils as n_utils"},{"line_number":20,"context_line":"from neutron.i18n import _LE, _LI"},{"line_number":21,"context_line":"from neutron.plugins.ml2.drivers.linuxbridge.agent \\"},{"line_number":22,"context_line":"    import linuxbridge_neutron_agent"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"LOG \u003d logging.getLogger(__name__)"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_b56d099a","line":22,"updated":"2015-09-16 06:24:32.000000000","message":"doesn\u0027t this indirectly import LB\u0027s config.py and register options?","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"2156a70b21a3ff7a93f17e48c20e6b39fd77075b","unresolved":false,"context_lines":[{"line_number":19,"context_line":"from neutron.common import utils as n_utils"},{"line_number":20,"context_line":"from neutron.i18n import _LE, _LI"},{"line_number":21,"context_line":"from neutron.plugins.ml2.drivers.linuxbridge.agent \\"},{"line_number":22,"context_line":"    import linuxbridge_neutron_agent"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"LOG \u003d logging.getLogger(__name__)"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_e6d97523","line":22,"in_reply_to":"ba15a1d1_b56d099a","updated":"2015-09-16 22:30:29.000000000","message":"Does it? Would it mean I can remove setup_conf and directly use cfg.conf in remove_empty_bridges()?","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"73abde0b846df84e86b7000ceb1641072aba3447","unresolved":false,"context_lines":[{"line_number":19,"context_line":"from neutron.common import utils as n_utils"},{"line_number":20,"context_line":"from neutron.i18n import _LE, _LI"},{"line_number":21,"context_line":"from neutron.plugins.ml2.drivers.linuxbridge.agent \\"},{"line_number":22,"context_line":"    import linuxbridge_neutron_agent"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"LOG \u003d logging.getLogger(__name__)"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_6bc3e689","line":22,"in_reply_to":"ba15a1d1_e6d97523","updated":"2015-09-17 04:23:48.000000000","message":"i think so, yes.","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"43348e8957fac3326a9f1bc7c8eab9ef95fc116f","unresolved":false,"context_lines":[{"line_number":28,"context_line":"def setup_conf():"},{"line_number":29,"context_line":"    conf \u003d cfg.CONF"},{"line_number":30,"context_line":"    conf.import_opt(\u0027physical_interface_mappings\u0027,"},{"line_number":31,"context_line":"                    \u0027neutron.plugins.linuxbridge.common.config\u0027,"},{"line_number":32,"context_line":"                    group\u003d\u0027LINUX_BRIDGE\u0027)"},{"line_number":33,"context_line":"    conf.import_opt(\u0027bridge_mappings\u0027,"},{"line_number":34,"context_line":"                    \u0027neutron.plugins.linuxbridge.common.config\u0027,"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_55f7cdf4","line":31,"updated":"2015-09-16 06:24:32.000000000","message":"stale path","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"2156a70b21a3ff7a93f17e48c20e6b39fd77075b","unresolved":false,"context_lines":[{"line_number":28,"context_line":"def setup_conf():"},{"line_number":29,"context_line":"    conf \u003d cfg.CONF"},{"line_number":30,"context_line":"    conf.import_opt(\u0027physical_interface_mappings\u0027,"},{"line_number":31,"context_line":"                    \u0027neutron.plugins.linuxbridge.common.config\u0027,"},{"line_number":32,"context_line":"                    group\u003d\u0027LINUX_BRIDGE\u0027)"},{"line_number":33,"context_line":"    conf.import_opt(\u0027bridge_mappings\u0027,"},{"line_number":34,"context_line":"                    \u0027neutron.plugins.linuxbridge.common.config\u0027,"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_6697a53a","line":31,"in_reply_to":"ba15a1d1_55f7cdf4","updated":"2015-09-16 22:30:29.000000000","message":"Done","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"43348e8957fac3326a9f1bc7c8eab9ef95fc116f","unresolved":false,"context_lines":[{"line_number":31,"context_line":"                    \u0027neutron.plugins.linuxbridge.common.config\u0027,"},{"line_number":32,"context_line":"                    group\u003d\u0027LINUX_BRIDGE\u0027)"},{"line_number":33,"context_line":"    conf.import_opt(\u0027bridge_mappings\u0027,"},{"line_number":34,"context_line":"                    \u0027neutron.plugins.linuxbridge.common.config\u0027,"},{"line_number":35,"context_line":"                    group\u003d\u0027LINUX_BRIDGE\u0027)"},{"line_number":36,"context_line":"    return conf"},{"line_number":37,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_f5de216c","line":34,"updated":"2015-09-16 06:24:32.000000000","message":"ditto","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"2156a70b21a3ff7a93f17e48c20e6b39fd77075b","unresolved":false,"context_lines":[{"line_number":31,"context_line":"                    \u0027neutron.plugins.linuxbridge.common.config\u0027,"},{"line_number":32,"context_line":"                    group\u003d\u0027LINUX_BRIDGE\u0027)"},{"line_number":33,"context_line":"    conf.import_opt(\u0027bridge_mappings\u0027,"},{"line_number":34,"context_line":"                    \u0027neutron.plugins.linuxbridge.common.config\u0027,"},{"line_number":35,"context_line":"                    group\u003d\u0027LINUX_BRIDGE\u0027)"},{"line_number":36,"context_line":"    return conf"},{"line_number":37,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_26a68dae","line":34,"in_reply_to":"ba15a1d1_f5de216c","updated":"2015-09-16 22:30:29.000000000","message":"Done","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"43348e8957fac3326a9f1bc7c8eab9ef95fc116f","unresolved":false,"context_lines":[{"line_number":54,"context_line":"    LOG.info(_LI(\"Bridge mappings: %s\"), bridge_mappings)"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("},{"line_number":57,"context_line":"        bridge_mappings, interface_mappings)"},{"line_number":58,"context_line":"    LOG.info(_LI(\"Agent initialized successfully, now running... \"))"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    bridges \u003d lb_manager.get_all_neutron_bridges()"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_552a6d2d","line":57,"updated":"2015-09-16 06:24:32.000000000","message":"scaring implementation...","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"2156a70b21a3ff7a93f17e48c20e6b39fd77075b","unresolved":false,"context_lines":[{"line_number":54,"context_line":"    LOG.info(_LI(\"Bridge mappings: %s\"), bridge_mappings)"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("},{"line_number":57,"context_line":"        bridge_mappings, interface_mappings)"},{"line_number":58,"context_line":"    LOG.info(_LI(\"Agent initialized successfully, now running... \"))"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    bridges \u003d lb_manager.get_all_neutron_bridges()"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_c696b13e","line":57,"in_reply_to":"ba15a1d1_552a6d2d","updated":"2015-09-16 22:30:29.000000000","message":"Do you have an alternative implementation to propose?","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"43348e8957fac3326a9f1bc7c8eab9ef95fc116f","unresolved":false,"context_lines":[{"line_number":60,"context_line":"    bridges \u003d lb_manager.get_all_neutron_bridges()"},{"line_number":61,"context_line":"    for bridge in bridges:"},{"line_number":62,"context_line":"        if not lb_manager.get_tap_devices_count(bridge):"},{"line_number":63,"context_line":"            lb_manager.delete_vlan_bridge(bridge)"},{"line_number":64,"context_line":"    LOG.info(_LI(\"LinuxBridge cleanup completed successfully\"))"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_953005a0","line":63,"updated":"2015-09-16 06:24:32.000000000","message":"master no longer has delete_vlan_bridge.","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"2156a70b21a3ff7a93f17e48c20e6b39fd77075b","unresolved":false,"context_lines":[{"line_number":60,"context_line":"    bridges \u003d lb_manager.get_all_neutron_bridges()"},{"line_number":61,"context_line":"    for bridge in bridges:"},{"line_number":62,"context_line":"        if not lb_manager.get_tap_devices_count(bridge):"},{"line_number":63,"context_line":"            lb_manager.delete_vlan_bridge(bridge)"},{"line_number":64,"context_line":"    LOG.info(_LI(\"LinuxBridge cleanup completed successfully\"))"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_66e6c5b1","line":63,"in_reply_to":"ba15a1d1_953005a0","updated":"2015-09-16 22:30:29.000000000","message":"Done","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":15070,"name":"Ruijing","email":"ruijing.guo@intel.com","username":"ruijing"},"change_message_id":"b60e401f8b5eef5a254178b8df3ed97b4a83386f","unresolved":false,"context_lines":[{"line_number":66,"context_line":""},{"line_number":67,"context_line":"def main():"},{"line_number":68,"context_line":"    conf \u003d setup_conf()"},{"line_number":69,"context_line":"    conf()"},{"line_number":70,"context_line":"    config.setup_logging()"},{"line_number":71,"context_line":"    remove_empty_bridges(conf)"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_c95108da","line":69,"updated":"2015-09-16 08:47:06.000000000","message":"why need conf()","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"2156a70b21a3ff7a93f17e48c20e6b39fd77075b","unresolved":false,"context_lines":[{"line_number":66,"context_line":""},{"line_number":67,"context_line":"def main():"},{"line_number":68,"context_line":"    conf \u003d setup_conf()"},{"line_number":69,"context_line":"    conf()"},{"line_number":70,"context_line":"    config.setup_logging()"},{"line_number":71,"context_line":"    remove_empty_bridges(conf)"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba15a1d1_c6a8f18f","line":69,"in_reply_to":"ba15a1d1_c95108da","updated":"2015-09-16 22:30:29.000000000","message":"Monkey see, monkey do. See netns_cleanup.py and ovs_cleanup.py","commit_id":"48b882aeefa02738834e1d7d77b65691873910eb"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"99449c502e94500f3e4a6dc365acacd5984293f8","unresolved":false,"context_lines":[{"line_number":25,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"def setup_conf():"},{"line_number":29,"context_line":"    conf \u003d cfg.CONF"},{"line_number":30,"context_line":"    conf.import_opt("},{"line_number":31,"context_line":"        \u0027physical_interface_mappings\u0027,"}],"source_content_type":"text/x-python","patch_set":7,"id":"ba15a1d1_4bfb82c1","line":28,"updated":"2015-09-17 04:28:49.000000000","message":"as commented on the previous PS, this seems redundant.","commit_id":"61c28fdf31d5e8a0ff38077a4b5e97634c0f3d28"},{"author":{"_account_id":7156,"name":"Mathieu Gagné","email":"mgagne@calavera.ca","username":"mgagne"},"change_message_id":"0cb0070d09f2f0ec370a242e07b4fa97affe1c49","unresolved":false,"context_lines":[{"line_number":25,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"def setup_conf():"},{"line_number":29,"context_line":"    conf \u003d cfg.CONF"},{"line_number":30,"context_line":"    conf.import_opt("},{"line_number":31,"context_line":"        \u0027physical_interface_mappings\u0027,"}],"source_content_type":"text/x-python","patch_set":7,"id":"ba15a1d1_7c185fd3","line":28,"in_reply_to":"ba15a1d1_4bfb82c1","updated":"2015-09-17 21:57:49.000000000","message":"Done","commit_id":"61c28fdf31d5e8a0ff38077a4b5e97634c0f3d28"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"7e04ee2980df168199b8702f14f84bf4c45fa2e4","unresolved":false,"context_lines":[{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    bridge_names \u003d lb_manager.get_all_neutron_bridges()"},{"line_number":50,"context_line":"    for bridge_name in bridge_names:"},{"line_number":51,"context_line":"        # NOTE(mgagne) Don\u0027t remove pre-existing user-defined bridges"},{"line_number":52,"context_line":"        if bridge_name in bridge_mappings:"},{"line_number":53,"context_line":"            continue"},{"line_number":54,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"}],"source_content_type":"text/x-python","patch_set":11,"id":"9a1a9d01_127c6b71","line":51,"updated":"2015-09-24 22:36:22.000000000","message":"sadly it does remove them as it should:\n\n if bridge_name in bridge_mappings.values():","commit_id":"4e6e47b42578e2ed81af73c178e1b69ef521e252"},{"author":{"_account_id":11307,"name":"Andreas Scheuring","email":"andreas.scheuring@de.ibm.com","username":"uniqueName"},"change_message_id":"6dd183486b46a87c29cf4d373b68c3846dedede5","unresolved":false,"context_lines":[{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("},{"line_number":46,"context_line":"        bridge_mappings, interface_mappings)"},{"line_number":47,"context_line":"    LOG.info(_LI(\"Agent initialized successfully, now running... \"))"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    # NOTE(mgagne) Don\u0027t remove pre-existing user-defined bridges"},{"line_number":50,"context_line":"    bridge_names \u003d set(lb_manager.get_all_neutron_bridges())"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_6efe046d","line":47,"updated":"2015-09-25 17:17:09.000000000","message":"nit: It\u0027s not really the agent your initializing, but just the BridgeManager object, which holds all the states and so on, right? So running might be a bit confusing as well, as the agent is not really running. However, this is nit-picking.","commit_id":"e5a1e92f49e842c7c83bbc77179d5e5a18f91eb8"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"abe92086b51afc9aa15e3b8c48bdc3f2e50e0252","unresolved":false,"context_lines":[{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("},{"line_number":46,"context_line":"        bridge_mappings, interface_mappings)"},{"line_number":47,"context_line":"    LOG.info(_LI(\"Agent initialized successfully, now running... \"))"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    # NOTE(mgagne) Don\u0027t remove pre-existing user-defined bridges"},{"line_number":50,"context_line":"    bridge_names \u003d set(lb_manager.get_all_neutron_bridges())"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_473c152f","line":47,"in_reply_to":"9a1a9d01_1371a4e0","updated":"2015-09-28 19:27:30.000000000","message":"Done","commit_id":"e5a1e92f49e842c7c83bbc77179d5e5a18f91eb8"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"da9cd82dc4a70867808a1abe1d2006034b2ea167","unresolved":false,"context_lines":[{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("},{"line_number":46,"context_line":"        bridge_mappings, interface_mappings)"},{"line_number":47,"context_line":"    LOG.info(_LI(\"Agent initialized successfully, now running... \"))"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    # NOTE(mgagne) Don\u0027t remove pre-existing user-defined bridges"},{"line_number":50,"context_line":"    bridge_names \u003d set(lb_manager.get_all_neutron_bridges())"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_1371a4e0","line":47,"in_reply_to":"9a1a9d01_6efe046d","updated":"2015-09-25 23:25:01.000000000","message":"Remove \u0027Agent\u0027?","commit_id":"e5a1e92f49e842c7c83bbc77179d5e5a18f91eb8"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"da9cd82dc4a70867808a1abe1d2006034b2ea167","unresolved":false,"context_lines":[{"line_number":58,"context_line":""},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"def main():"},{"line_number":61,"context_line":"    cfg.CONF(sys.argv[1:])"},{"line_number":62,"context_line":"    config.setup_logging()"},{"line_number":63,"context_line":"    remove_empty_bridges()"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_3332a811","line":61,"updated":"2015-09-25 23:25:01.000000000","message":"suggest: \nAdd a warning information to warn:\nTo avoid potential race condition with other components,  please make sure there is no others are operating on linux bridge, whatever\n\nAdd a continue confirmation to request go,\nand add a flag --force True to skip the confirmation","commit_id":"e5a1e92f49e842c7c83bbc77179d5e5a18f91eb8"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"ffc499a79f842f084726d72f0b406185894e8090","unresolved":false,"context_lines":[{"line_number":53,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"},{"line_number":54,"context_line":"            lb_manager.delete_bridge(bridge_name)"},{"line_number":55,"context_line":"            LOG.info(_LI(\"LinuxBridge %s deleted\"), bridge_name)"},{"line_number":56,"context_line":"    LOG.info(_LI(\"LinuxBridge cleanup completed successfully\"))"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"def main():"}],"source_content_type":"text/x-python","patch_set":13,"id":"9a1a9d01_2eb1b647","line":56,"updated":"2015-09-28 14:30:45.000000000","message":"LinuxBridge -\u003e Linux bridge?","commit_id":"c3db37af72c88b52fa8ee343cc9c79e6a2b4e36b"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"ffc499a79f842f084726d72f0b406185894e8090","unresolved":false,"context_lines":[{"line_number":56,"context_line":"    LOG.info(_LI(\"LinuxBridge cleanup completed successfully\"))"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"def main():"},{"line_number":60,"context_line":"    cfg.CONF(sys.argv[1:])"},{"line_number":61,"context_line":"    config.setup_logging()"},{"line_number":62,"context_line":"    remove_empty_bridges()"}],"source_content_type":"text/x-python","patch_set":13,"id":"9a1a9d01_ce935a4e","line":59,"updated":"2015-09-28 14:30:45.000000000","message":"please add doc about what it does,  maybe https://github.com/openstack/neutron/blob/master/neutron/cmd/netns_cleanup.py is a good example. thanks.","commit_id":"c3db37af72c88b52fa8ee343cc9c79e6a2b4e36b"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"044a820a8f195c0f2fb954de69173f34f803be83","unresolved":false,"context_lines":[{"line_number":32,"context_line":"    except ValueError as e:"},{"line_number":33,"context_line":"        LOG.error(_LE(\"Parsing physical_interface_mappings failed: %s.\"), e)"},{"line_number":34,"context_line":"        sys.exit(1)"},{"line_number":35,"context_line":"    LOG.info(_LI(\"Interface mappings: %s\"), interface_mappings)"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    try:"},{"line_number":38,"context_line":"        bridge_mappings \u003d n_utils.parse_mappings("}],"source_content_type":"text/x-python","patch_set":15,"id":"9a1a9d01_10587a89","line":35,"updated":"2015-09-28 22:55:50.000000000","message":"In this doc, sometimes we end text with period, sometimes without it.","commit_id":"938307bbeec468464bfdd90c44f88b7b7eba657f"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"8d8c83b21ab68167d513655fdb21b1fe1bedce59","unresolved":false,"context_lines":[{"line_number":32,"context_line":"    except ValueError as e:"},{"line_number":33,"context_line":"        LOG.error(_LE(\"Parsing physical_interface_mappings failed: %s.\"), e)"},{"line_number":34,"context_line":"        sys.exit(1)"},{"line_number":35,"context_line":"    LOG.info(_LI(\"Interface mappings: %s\"), interface_mappings)"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    try:"},{"line_number":38,"context_line":"        bridge_mappings \u003d n_utils.parse_mappings("}],"source_content_type":"text/x-python","patch_set":15,"id":"9a1a9d01_9c281788","line":35,"in_reply_to":"9a1a9d01_10587a89","updated":"2015-09-29 08:21:43.000000000","message":"Done","commit_id":"938307bbeec468464bfdd90c44f88b7b7eba657f"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"044a820a8f195c0f2fb954de69173f34f803be83","unresolved":false,"context_lines":[{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    # NOTE(mgagne) Don\u0027t remove pre-existing user-defined bridges"},{"line_number":49,"context_line":"    bridge_names \u003d set(lb_manager.get_all_neutron_bridges())"},{"line_number":50,"context_line":"    bridge_names -\u003d set(bridge_mappings.values())"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    for bridge_name in bridge_names:"},{"line_number":53,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a1a9d01_db154340","line":50,"updated":"2015-09-28 22:55:50.000000000","message":"It is crazy to have the same name for bridge_mappings and neutron managed bridges. But possible :)","commit_id":"938307bbeec468464bfdd90c44f88b7b7eba657f"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"8d8c83b21ab68167d513655fdb21b1fe1bedce59","unresolved":false,"context_lines":[{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    # NOTE(mgagne) Don\u0027t remove pre-existing user-defined bridges"},{"line_number":49,"context_line":"    bridge_names \u003d set(lb_manager.get_all_neutron_bridges())"},{"line_number":50,"context_line":"    bridge_names -\u003d set(bridge_mappings.values())"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    for bridge_name in bridge_names:"},{"line_number":53,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a1a9d01_1c3de7c3","line":50,"in_reply_to":"9a1a9d01_db154340","updated":"2015-09-29 08:21:43.000000000","message":"Crazy but possible as you said","commit_id":"938307bbeec468464bfdd90c44f88b7b7eba657f"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"044a820a8f195c0f2fb954de69173f34f803be83","unresolved":false,"context_lines":[{"line_number":59,"context_line":"def main():"},{"line_number":60,"context_line":"    \"\"\"Main method for cleaning up empty linux bridges."},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"    This tool deletes every empty linux bridge managed by linuxbridge agent"},{"line_number":63,"context_line":"    except the ones defined in bridge_mappings (created by deployers)."},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"    This tool should not be called during an instance create, migrate, etc. as"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a1a9d01_b0f74e58","line":62,"updated":"2015-09-28 22:55:50.000000000","message":"had better to record the bridge names\u0027 pattern here.","commit_id":"938307bbeec468464bfdd90c44f88b7b7eba657f"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"8d8c83b21ab68167d513655fdb21b1fe1bedce59","unresolved":false,"context_lines":[{"line_number":59,"context_line":"def main():"},{"line_number":60,"context_line":"    \"\"\"Main method for cleaning up empty linux bridges."},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"    This tool deletes every empty linux bridge managed by linuxbridge agent"},{"line_number":63,"context_line":"    except the ones defined in bridge_mappings (created by deployers)."},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"    This tool should not be called during an instance create, migrate, etc. as"}],"source_content_type":"text/x-python","patch_set":15,"id":"9a1a9d01_dc1bef71","line":62,"in_reply_to":"9a1a9d01_b0f74e58","updated":"2015-09-29 08:21:43.000000000","message":"Done","commit_id":"938307bbeec468464bfdd90c44f88b7b7eba657f"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"915f27959f615abe79c197573fd4afa41d10ce4c","unresolved":false,"context_lines":[{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    for bridge_name in bridge_names:"},{"line_number":53,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"},{"line_number":54,"context_line":"            lb_manager.delete_bridge(bridge_name)"},{"line_number":55,"context_line":"            LOG.info(_LI(\"LinuxBridge %s deleted\"), bridge_name)"},{"line_number":56,"context_line":"    LOG.info(_LI(\"Linux bridge cleanup completed successfully\"))"},{"line_number":57,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_054a6755","line":54,"updated":"2015-09-29 11:39:38.000000000","message":"what if this fails? should we continue to the next one?","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"9d91e2442d68f09a6b2c0ba7d877414137306ad0","unresolved":false,"context_lines":[{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    for bridge_name in bridge_names:"},{"line_number":53,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"},{"line_number":54,"context_line":"            lb_manager.delete_bridge(bridge_name)"},{"line_number":55,"context_line":"            LOG.info(_LI(\"LinuxBridge %s deleted\"), bridge_name)"},{"line_number":56,"context_line":"    LOG.info(_LI(\"Linux bridge cleanup completed successfully\"))"},{"line_number":57,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_67a32301","line":54,"in_reply_to":"9a1a9d01_054a6755","updated":"2015-09-29 13:31:42.000000000","message":"maybe we should just Log it and then continue","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"},{"author":{"_account_id":4187,"name":"Ryan Tidwell","email":"rtidwell@suse.com","username":"ryan-tidwell"},"change_message_id":"310f8b593e1807e2aed8fbd96b3ab553aec39893","unresolved":false,"context_lines":[{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    for bridge_name in bridge_names:"},{"line_number":53,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"},{"line_number":54,"context_line":"            lb_manager.delete_bridge(bridge_name)"},{"line_number":55,"context_line":"            LOG.info(_LI(\"LinuxBridge %s deleted\"), bridge_name)"},{"line_number":56,"context_line":"    LOG.info(_LI(\"Linux bridge cleanup completed successfully\"))"},{"line_number":57,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_a8d45eeb","line":54,"in_reply_to":"9a1a9d01_67a32301","updated":"2015-09-30 22:42:31.000000000","message":"I think this loop should continue, but we probably should make the user aware if deleting a bridge fails.  The idea with this is to clean up a large number of unused bridges that otherwise would have to be painstakingly removed by hand.  We should clean up what we can and alert the user to any bridges not removed by this code.","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"3c84d019e15f17db8ef6c905bb0e804dd8dfb454","unresolved":false,"context_lines":[{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    for bridge_name in bridge_names:"},{"line_number":53,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"},{"line_number":54,"context_line":"            lb_manager.delete_bridge(bridge_name)"},{"line_number":55,"context_line":"            LOG.info(_LI(\"LinuxBridge %s deleted\"), bridge_name)"},{"line_number":56,"context_line":"    LOG.info(_LI(\"Linux bridge cleanup completed successfully\"))"},{"line_number":57,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_3e093bde","line":54,"in_reply_to":"9a1a9d01_a8d45eeb","updated":"2015-10-01 19:50:48.000000000","message":"Done","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"9d91e2442d68f09a6b2c0ba7d877414137306ad0","unresolved":false,"context_lines":[{"line_number":52,"context_line":"    for bridge_name in bridge_names:"},{"line_number":53,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"},{"line_number":54,"context_line":"            lb_manager.delete_bridge(bridge_name)"},{"line_number":55,"context_line":"            LOG.info(_LI(\"LinuxBridge %s deleted\"), bridge_name)"},{"line_number":56,"context_line":"    LOG.info(_LI(\"Linux bridge cleanup completed successfully\"))"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_47685fb9","line":55,"updated":"2015-09-29 13:31:42.000000000","message":"LinuxBridge -\u003e Linux bridge","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"3c84d019e15f17db8ef6c905bb0e804dd8dfb454","unresolved":false,"context_lines":[{"line_number":52,"context_line":"    for bridge_name in bridge_names:"},{"line_number":53,"context_line":"        if not lb_manager.get_tap_devices_count(bridge_name):"},{"line_number":54,"context_line":"            lb_manager.delete_bridge(bridge_name)"},{"line_number":55,"context_line":"            LOG.info(_LI(\"LinuxBridge %s deleted\"), bridge_name)"},{"line_number":56,"context_line":"    LOG.info(_LI(\"Linux bridge cleanup completed successfully\"))"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_9ef887c6","line":55,"in_reply_to":"9a1a9d01_47685fb9","updated":"2015-10-01 19:50:48.000000000","message":"Oups \u003d\u003e Done","commit_id":"51de136c14d9eaed4ab4a9a0eed0b652cef527e2"},{"author":{"_account_id":14064,"name":"Kahou Lei","email":"kahou82@gmail.com","username":"kahou82"},"change_message_id":"7e2058f5cb7198f480d828f5b551b807c24c8c72","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            cfg.CONF.LINUX_BRIDGE.bridge_mappings)"},{"line_number":40,"context_line":"    except ValueError as e:"},{"line_number":41,"context_line":"        LOG.error(_LE(\"Parsing bridge_mappings failed: %s.\"), e)"},{"line_number":42,"context_line":"        sys.exit(1)"},{"line_number":43,"context_line":"    LOG.info(_LI(\"Bridge mappings: %s.\"), bridge_mappings)"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("}],"source_content_type":"text/x-python","patch_set":19,"id":"9a1a9d01_4e3453fa","line":42,"updated":"2015-10-02 18:29:17.000000000","message":"Just wonder is it a must? The reason is that prior to Kilo, we don\u0027t have bridge mappings options. If we enforce user to have that, will it break backward compatibility?","commit_id":"27f60c314bc9de5d81571de1437f93ca232f1382"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"ae1cf3c70d8baf00e928ffe25ea7be6113a6502d","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            cfg.CONF.LINUX_BRIDGE.bridge_mappings)"},{"line_number":40,"context_line":"    except ValueError as e:"},{"line_number":41,"context_line":"        LOG.error(_LE(\"Parsing bridge_mappings failed: %s.\"), e)"},{"line_number":42,"context_line":"        sys.exit(1)"},{"line_number":43,"context_line":"    LOG.info(_LI(\"Bridge mappings: %s.\"), bridge_mappings)"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    lb_manager \u003d linuxbridge_neutron_agent.LinuxBridgeManager("}],"source_content_type":"text/x-python","patch_set":19,"id":"9a1a9d01_f9aacf84","line":42,"in_reply_to":"9a1a9d01_4e3453fa","updated":"2015-10-02 18:40:19.000000000","message":"No: the script fails to parse cfg.CONF.LINUX_BRIDGE.bridge_mappings if cfg.CONF.LINUX_BRIDGE.bridge_mappings value is incorrect (which implies you have specified a value)","commit_id":"27f60c314bc9de5d81571de1437f93ca232f1382"}],"neutron/tests/fullstack/cmd/test_linuxbridge_cleanup.py":[{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"1b267194f350c063ea5c39b9fe5f23dcb332466e","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright (c) 2015 Thales Services SAS"},{"line_number":2,"context_line":"# All Rights Reserved."},{"line_number":3,"context_line":"#"},{"line_number":4,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"}],"source_content_type":"text/x-python","patch_set":10,"id":"ba15a1d1_640581c0","line":1,"updated":"2015-09-22 22:35:31.000000000","message":"Not sure, if this test module should in fullstack or functional?","commit_id":"4d1c6c85c73c4279ee88b4d9e9a4fd8853c6d4a0"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"d3fde570f62888a4351fcdfc46dbd51eec75c9c8","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright (c) 2015 Thales Services SAS"},{"line_number":2,"context_line":"# All Rights Reserved."},{"line_number":3,"context_line":"#"},{"line_number":4,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_89905bee","line":1,"in_reply_to":"9a1a9d01_3d039711","updated":"2015-09-24 19:15:40.000000000","message":"Done","commit_id":"4d1c6c85c73c4279ee88b4d9e9a4fd8853c6d4a0"},{"author":{"_account_id":6788,"name":"Rossella Sblendido","email":"rsblendido@suse.com","username":"rossella-o"},"change_message_id":"e90400bc9af17521696d2f060952885a7583f129","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright (c) 2015 Thales Services SAS"},{"line_number":2,"context_line":"# All Rights Reserved."},{"line_number":3,"context_line":"#"},{"line_number":4,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"}],"source_content_type":"text/x-python","patch_set":10,"id":"9a1a9d01_3d039711","line":1,"in_reply_to":"ba15a1d1_640581c0","updated":"2015-09-24 14:29:03.000000000","message":"I guess in functional...","commit_id":"4d1c6c85c73c4279ee88b4d9e9a4fd8853c6d4a0"}],"neutron/tests/functional/cmd/test_linuxbridge_cleanup.py":[{"author":{"_account_id":11307,"name":"Andreas Scheuring","email":"andreas.scheuring@de.ibm.com","username":"uniqueName"},"change_message_id":"6dd183486b46a87c29cf4d373b68c3846dedede5","unresolved":false,"context_lines":[{"line_number":82,"context_line":"        def callback(br_fixture):"},{"line_number":83,"context_line":"            br_name \u003d br_fixture.bridge.name"},{"line_number":84,"context_line":"            conf \u003d config_fixtures.ConfigDict()"},{"line_number":85,"context_line":"            conf.update({\u0027LINUX_BRIDGE\u0027: {\u0027bridge_mappings\u0027: \u0027physnet:%s\u0027 % br_name}})"},{"line_number":86,"context_line":"            return conf"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        self._test_linuxbridge_cleanup(True, callback)"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_2e27ac13","line":85,"updated":"2015-09-25 17:17:09.000000000","message":"pep8 complains line too long","commit_id":"e5a1e92f49e842c7c83bbc77179d5e5a18f91eb8"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"abe92086b51afc9aa15e3b8c48bdc3f2e50e0252","unresolved":false,"context_lines":[{"line_number":82,"context_line":"        def callback(br_fixture):"},{"line_number":83,"context_line":"            br_name \u003d br_fixture.bridge.name"},{"line_number":84,"context_line":"            conf \u003d config_fixtures.ConfigDict()"},{"line_number":85,"context_line":"            conf.update({\u0027LINUX_BRIDGE\u0027: {\u0027bridge_mappings\u0027: \u0027physnet:%s\u0027 % br_name}})"},{"line_number":86,"context_line":"            return conf"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        self._test_linuxbridge_cleanup(True, callback)"}],"source_content_type":"text/x-python","patch_set":12,"id":"9a1a9d01_a79651ee","line":85,"in_reply_to":"9a1a9d01_2e27ac13","updated":"2015-09-28 19:27:30.000000000","message":"Done","commit_id":"e5a1e92f49e842c7c83bbc77179d5e5a18f91eb8"}],"neutron/tests/tools.py":[{"author":{"_account_id":14064,"name":"Kahou Lei","email":"kahou82@gmail.com","username":"kahou82"},"change_message_id":"7e2058f5cb7198f480d828f5b551b807c24c8c72","unresolved":false,"context_lines":[{"line_number":77,"context_line":"            try:"},{"line_number":78,"context_line":"                self.fixture.cleanUp()"},{"line_number":79,"context_line":"            except Exception:"},{"line_number":80,"context_line":"                pass"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"        self.fixture.setUp()"},{"line_number":83,"context_line":"        self.addCleanup(cleanUp)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a1a9d01_99187377","line":80,"updated":"2015-10-02 18:29:17.000000000","message":"Just wonder do we want to swallow all the exception here? Can the exception be more specific?","commit_id":"27f60c314bc9de5d81571de1437f93ca232f1382"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"f1a4ef0b1e37fcc9c4accbd2f70f45fccea5101a","unresolved":false,"context_lines":[{"line_number":77,"context_line":"            try:"},{"line_number":78,"context_line":"                self.fixture.cleanUp()"},{"line_number":79,"context_line":"            except Exception:"},{"line_number":80,"context_line":"                pass"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"        self.fixture.setUp()"},{"line_number":83,"context_line":"        self.addCleanup(cleanUp)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a1a9d01_39dda714","line":80,"in_reply_to":"9a1a9d01_99187377","updated":"2015-10-02 18:42:37.000000000","message":"That\u0027s exactly the aim of the fixture: catch every exception raised during cleanup. If some change requires more specific catch then it will update the fixture to avoid YAGNI","commit_id":"27f60c314bc9de5d81571de1437f93ca232f1382"}]}
