)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"e63109fc87240fac0b2c5a779debc4789231a410","unresolved":false,"context_lines":[{"line_number":14,"context_line":"the config variable DEFAULT/ovs_lib_version."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"To play with it, make sure to have devstack"},{"line_number":17,"context_line":"  chmod a+rwx /var/run/openvswitch/db.sock."},{"line_number":18,"context_line":"when restarting openvswitch. Yes, permissions are a thing we\u0027ll have"},{"line_number":19,"context_line":"to work out. Also, in local.conf make sure that neutron.conf has"},{"line_number":20,"context_line":"something like:"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"5a890539_f6e1769b","line":17,"updated":"2014-11-08 11:24:39.000000000","message":"iiuc, such right update allows everyone to update OVS conf which is not acceptable from a security point of view","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":5756,"name":"Terry Wilson","email":"twilson@redhat.com","username":"otherwiseguy"},"change_message_id":"62754809b85294a7b8d149dbd248da24dbd17737","unresolved":false,"context_lines":[{"line_number":14,"context_line":"the config variable DEFAULT/ovs_lib_version."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"To play with it, make sure to have devstack"},{"line_number":17,"context_line":"  chmod a+rwx /var/run/openvswitch/db.sock."},{"line_number":18,"context_line":"when restarting openvswitch. Yes, permissions are a thing we\u0027ll have"},{"line_number":19,"context_line":"to work out. Also, in local.conf make sure that neutron.conf has"},{"line_number":20,"context_line":"something like:"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"3a961159_1f924c9f","line":17,"in_reply_to":"3a961159_c402c63d","updated":"2014-12-09 16:14:24.000000000","message":"Yeah, there are lots of options for doing this. I wouldn\u0027t expect anyone to run this before its merged on anything but test systems, and if they are I figure they can handle the permissions however they like.\n\nWhen actually using this in production, we\u0027ll have to come up with a real solution. This could be having init scripts/deployment tools/code with very specific rootwrap rule change the ownership, permissions, or ACLs. Or, we could set it up to be managed over TCP/SSL socket and control access via firewall rules.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"a2d577bbcbcbce8b157b07fa8cd69f0811520126","unresolved":false,"context_lines":[{"line_number":14,"context_line":"the config variable DEFAULT/ovs_lib_version."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"To play with it, make sure to have devstack"},{"line_number":17,"context_line":"  chmod a+rwx /var/run/openvswitch/db.sock."},{"line_number":18,"context_line":"when restarting openvswitch. Yes, permissions are a thing we\u0027ll have"},{"line_number":19,"context_line":"to work out. Also, in local.conf make sure that neutron.conf has"},{"line_number":20,"context_line":"something like:"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"3a961159_c402c63d","line":17,"in_reply_to":"5a890539_1b1d3d67","updated":"2014-12-09 11:00:17.000000000","message":"In most cases wouldn\u0027t it be enough to set the db.sock on neutron group, and give g+rwx ? \n\nAlso ACL\u0027s could be used for this:\n\n# setfacl -m u:neutron:rwx /var/run/openvswitch/db.sock  \n\nThis sets neutron for (rwx) independently of the file group and owner.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":8124,"name":"cbrandily","email":"zzelle@gmail.com","username":"cbrandily"},"change_message_id":"d50156fe1782a30f7bb49681768524c9a71212a2","unresolved":false,"context_lines":[{"line_number":14,"context_line":"the config variable DEFAULT/ovs_lib_version."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"To play with it, make sure to have devstack"},{"line_number":17,"context_line":"  chmod a+rwx /var/run/openvswitch/db.sock."},{"line_number":18,"context_line":"when restarting openvswitch. Yes, permissions are a thing we\u0027ll have"},{"line_number":19,"context_line":"to work out. Also, in local.conf make sure that neutron.conf has"},{"line_number":20,"context_line":"something like:"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"5a890539_1b1d3d67","line":17,"in_reply_to":"5a890539_8fe2cc01","updated":"2014-11-10 10:28:59.000000000","message":"waiting for it! :)\n\nBut you should add workflow \u003d\u003d -1","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":5756,"name":"Terry Wilson","email":"twilson@redhat.com","username":"otherwiseguy"},"change_message_id":"2f89f61e731a51cea07eb68dadc0de43311dd2d2","unresolved":false,"context_lines":[{"line_number":14,"context_line":"the config variable DEFAULT/ovs_lib_version."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"To play with it, make sure to have devstack"},{"line_number":17,"context_line":"  chmod a+rwx /var/run/openvswitch/db.sock."},{"line_number":18,"context_line":"when restarting openvswitch. Yes, permissions are a thing we\u0027ll have"},{"line_number":19,"context_line":"to work out. Also, in local.conf make sure that neutron.conf has"},{"line_number":20,"context_line":"something like:"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"5a890539_8fe2cc01","line":17,"in_reply_to":"5a890539_f6e1769b","updated":"2014-11-10 04:33:26.000000000","message":"Yes, of course. This is only \"to play with it\" for purposes of trying it out. There would need to be real work done in packaging/deployment tools to ensure that the permissions were appropriate for actual deployments. Other options would be to set things up to allow management over TCP/TLS and set ovs_conection\u003dpssl:6632 etc.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"}],"neutron/agent/linux/ovs_lib/ovs_lib2.py":[{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"7c1cb16c104c0ecd5e146851c33ed6b056dd279c","unresolved":false,"context_lines":[{"line_number":16,"context_line":"import itertools"},{"line_number":17,"context_line":"import operator"},{"line_number":18,"context_line":"import os"},{"line_number":19,"context_line":"from ovs.db import idl"},{"line_number":20,"context_line":"from ovs import jsonrpc"},{"line_number":21,"context_line":"import ovs.poller"},{"line_number":22,"context_line":"from ovs import stream"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_a65f980d","line":19,"updated":"2014-11-11 09:00:33.000000000","message":"I assume \u0027ovs\u0027 is an external library of some sort? Then it should be below (with oslo.config)","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":5756,"name":"Terry Wilson","email":"twilson@redhat.com","username":"otherwiseguy"},"change_message_id":"0c3faec402da6900f5e3b1c215f2acdec957acf3","unresolved":false,"context_lines":[{"line_number":16,"context_line":"import itertools"},{"line_number":17,"context_line":"import operator"},{"line_number":18,"context_line":"import os"},{"line_number":19,"context_line":"from ovs.db import idl"},{"line_number":20,"context_line":"from ovs import jsonrpc"},{"line_number":21,"context_line":"import ovs.poller"},{"line_number":22,"context_line":"from ovs import stream"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_28428410","line":19,"in_reply_to":"5a890539_a65f980d","updated":"2014-11-11 18:27:47.000000000","message":"Ah, yes. Good point.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"7c1cb16c104c0ecd5e146851c33ed6b056dd279c","unresolved":false,"context_lines":[{"line_number":122,"context_line":"            self.commit()"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"class VifPort:"},{"line_number":126,"context_line":"    def __init__(self, port_name, ofport, vif_id, vif_mac, switch):"},{"line_number":127,"context_line":"        self.port_name \u003d port_name"},{"line_number":128,"context_line":"        self.ofport \u003d ofport"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_c62664ba","line":125,"updated":"2014-11-11 09:00:33.000000000","message":"Any reason why this isn\u0027t a newtype class (inherits from object)?","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":5756,"name":"Terry Wilson","email":"twilson@redhat.com","username":"otherwiseguy"},"change_message_id":"0c3faec402da6900f5e3b1c215f2acdec957acf3","unresolved":false,"context_lines":[{"line_number":122,"context_line":"            self.commit()"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"class VifPort:"},{"line_number":126,"context_line":"    def __init__(self, port_name, ofport, vif_id, vif_mac, switch):"},{"line_number":127,"context_line":"        self.port_name \u003d port_name"},{"line_number":128,"context_line":"        self.ofport \u003d ofport"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_f4ee9c8a","line":125,"in_reply_to":"5a890539_c62664ba","updated":"2014-11-11 18:27:47.000000000","message":"It is just copied from ovs_lib1. No changes by me here, so I\u0027m not really sure.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"7c1cb16c104c0ecd5e146851c33ed6b056dd279c","unresolved":false,"context_lines":[{"line_number":141,"context_line":"    seqno \u003d idl.change_seqno"},{"line_number":142,"context_line":"    stop \u003d time.time() + cfg.CONF.ovs_vsctl_timeout"},{"line_number":143,"context_line":"    while idl.change_seqno \u003d\u003d seqno and not idl.run():"},{"line_number":144,"context_line":"        poller \u003d ovs.poller.Poller()"},{"line_number":145,"context_line":"        idl.wait(poller)"},{"line_number":146,"context_line":"        poller.block()"},{"line_number":147,"context_line":"        if time.time() \u003e stop:"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_06acec9f","line":144,"updated":"2014-11-11 09:00:33.000000000","message":"Why is \u0027poller\u0027 re-initialized for each loop?","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":5756,"name":"Terry Wilson","email":"twilson@redhat.com","username":"otherwiseguy"},"change_message_id":"0c3faec402da6900f5e3b1c215f2acdec957acf3","unresolved":false,"context_lines":[{"line_number":141,"context_line":"    seqno \u003d idl.change_seqno"},{"line_number":142,"context_line":"    stop \u003d time.time() + cfg.CONF.ovs_vsctl_timeout"},{"line_number":143,"context_line":"    while idl.change_seqno \u003d\u003d seqno and not idl.run():"},{"line_number":144,"context_line":"        poller \u003d ovs.poller.Poller()"},{"line_number":145,"context_line":"        idl.wait(poller)"},{"line_number":146,"context_line":"        poller.block()"},{"line_number":147,"context_line":"        if time.time() \u003e stop:"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_e8e95c1b","line":144,"in_reply_to":"5a890539_06acec9f","updated":"2014-11-11 18:27:47.000000000","message":"It ensures that the poller timeout is reset after the wait. See https://github.com/openvswitch/ovs/blob/master/python/ovs/poller.py timer_wait/immediate_wake, etc.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"7c1cb16c104c0ecd5e146851c33ed6b056dd279c","unresolved":false,"context_lines":[{"line_number":145,"context_line":"        idl.wait(poller)"},{"line_number":146,"context_line":"        poller.block()"},{"line_number":147,"context_line":"        if time.time() \u003e stop:"},{"line_number":148,"context_line":"            raise exceptions.RetryTimeoutError"},{"line_number":149,"context_line":""},{"line_number":150,"context_line":""},{"line_number":151,"context_line":"class BaseOVS(object):"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_663770e4","line":148,"updated":"2014-11-11 09:00:33.000000000","message":"Why not throw instances instead?\n\n raise exceptions.RetryTimeoutError()","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":5756,"name":"Terry Wilson","email":"twilson@redhat.com","username":"otherwiseguy"},"change_message_id":"0c3faec402da6900f5e3b1c215f2acdec957acf3","unresolved":false,"context_lines":[{"line_number":145,"context_line":"        idl.wait(poller)"},{"line_number":146,"context_line":"        poller.block()"},{"line_number":147,"context_line":"        if time.time() \u003e stop:"},{"line_number":148,"context_line":"            raise exceptions.RetryTimeoutError"},{"line_number":149,"context_line":""},{"line_number":150,"context_line":""},{"line_number":151,"context_line":"class BaseOVS(object):"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_c81ae06d","line":148,"in_reply_to":"5a890539_663770e4","updated":"2014-11-11 18:27:47.000000000","message":"Because I messed up. :D Will fix.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"7c1cb16c104c0ecd5e146851c33ed6b056dd279c","unresolved":false,"context_lines":[{"line_number":253,"context_line":"        # This is annoyingly inefficient, but probably still more efficient"},{"line_number":254,"context_line":"        # than doing network communication. I really wish the IDL"},{"line_number":255,"context_line":"        # implementation maintained references from iface-\u003eport-\u003ebridge like"},{"line_number":256,"context_line":"        # the C implementation does."},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"        try:"},{"line_number":259,"context_line":"            iface \u003d self._row_by_name(iface, \u0027Interface\u0027)"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_46f994c7","line":256,"updated":"2014-11-11 09:00:33.000000000","message":"I don\u0027t know what format IDL holds it, but may be it\u0027s worth (on startup) reading all this data and maintaining the references manually?\n\nHow often is \u0027get_bridge_for_iface\u0027 used? If it\u0027s a lot, then reading the data on startup might be an actual solution to this.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":5756,"name":"Terry Wilson","email":"twilson@redhat.com","username":"otherwiseguy"},"change_message_id":"0c3faec402da6900f5e3b1c215f2acdec957acf3","unresolved":false,"context_lines":[{"line_number":253,"context_line":"        # This is annoyingly inefficient, but probably still more efficient"},{"line_number":254,"context_line":"        # than doing network communication. I really wish the IDL"},{"line_number":255,"context_line":"        # implementation maintained references from iface-\u003eport-\u003ebridge like"},{"line_number":256,"context_line":"        # the C implementation does."},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"        try:"},{"line_number":259,"context_line":"            iface \u003d self._row_by_name(iface, \u0027Interface\u0027)"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_5473f0e8","line":256,"in_reply_to":"5a890539_46f994c7","updated":"2014-11-11 18:27:47.000000000","message":"The IDL holds it in generic \"Row\" classes with some get/setattr handling for columns. I had an implementation where I cached that data on first use, but it essentially means going through every port/interface on a bridge and adding the links. Then if something changes, you have to go in and modify all of the links as well. It didn\u0027t seem worth it at the time, but maybe I should revisit it. I\u0027ll look at some VIF plugging examples and see if I can profile them. Whatever the case, I\u0027m sure it will be faster than ovs-vsctl having to dump the whole database to get the result.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"0f4d63d361b4d69601b74838bdd44c49832d4029","unresolved":false,"context_lines":[{"line_number":253,"context_line":"        # This is annoyingly inefficient, but probably still more efficient"},{"line_number":254,"context_line":"        # than doing network communication. I really wish the IDL"},{"line_number":255,"context_line":"        # implementation maintained references from iface-\u003eport-\u003ebridge like"},{"line_number":256,"context_line":"        # the C implementation does."},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"        try:"},{"line_number":259,"context_line":"            iface \u003d self._row_by_name(iface, \u0027Interface\u0027)"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_f4fdae3c","line":256,"in_reply_to":"5a890539_5473f0e8","updated":"2014-11-12 08:52:29.000000000","message":"Surely it would - the main reason I wrote this was that you seemed unsatisfied of the current implementation and caching it ourselves will probably fix this. I do see the overhead of caching it ourselves and keeping track of everything, so it might not be worth it eventually.\n\nAt the end of the day though, this is quite inefficient. Did you consider contributing code to the ovs repository directly to make these connections? For example, _row_by_name seems like a trivial thing to ask in the ovs python lib and will surely save some execution time. Probably other \u0027hacks\u0027 done here can be done much more easily inside ovslib itself.\n\nTaking this route is probably out of scope, but we might want to consider doing that as well (and when those changes hit, change this code appropriately).","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":12444,"name":"John Schwarz","email":"jschwarz@redhat.com","username":"jschwarz"},"change_message_id":"7c1cb16c104c0ecd5e146851c33ed6b056dd279c","unresolved":false,"context_lines":[{"line_number":742,"context_line":""},{"line_number":743,"context_line":""},{"line_number":744,"context_line":"def get_bridge_for_iface(root_helper, iface):"},{"line_number":745,"context_line":"    base \u003d BaseOVS(root_helper)"},{"line_number":746,"context_line":"    base._idl.run()"},{"line_number":747,"context_line":"    return base.get_bridge_for_iface(iface)"},{"line_number":748,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_0636ac52","line":745,"updated":"2014-11-11 09:00:33.000000000","message":"Will it be worthwhile to hold a single BaseOVS instance for these operations? Looks like the creation of BaseOVS might be expensive (creates some IDL classes as well).","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"},{"author":{"_account_id":5756,"name":"Terry Wilson","email":"twilson@redhat.com","username":"otherwiseguy"},"change_message_id":"0c3faec402da6900f5e3b1c215f2acdec957acf3","unresolved":false,"context_lines":[{"line_number":742,"context_line":""},{"line_number":743,"context_line":""},{"line_number":744,"context_line":"def get_bridge_for_iface(root_helper, iface):"},{"line_number":745,"context_line":"    base \u003d BaseOVS(root_helper)"},{"line_number":746,"context_line":"    base._idl.run()"},{"line_number":747,"context_line":"    return base.get_bridge_for_iface(iface)"},{"line_number":748,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a890539_54185081","line":745,"in_reply_to":"5a890539_0636ac52","updated":"2014-11-11 18:27:47.000000000","message":"BaseOVS only creates IDL stuff if it isn\u0027t already set on the class. Should only happen on the very first instance of BaseOVS for a module load.","commit_id":"81cca990ad9718bffd7c9e4c5136a7603969d2ef"}]}
