)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"936c6fea6a5f1b52ab8788814fecb1599213b943","unresolved":false,"context_lines":[{"line_number":7,"context_line":"logical_networks infra for network aware applications"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"LogicalNetworks is a common infra that holds different types of network"},{"line_number":10,"context_line":"ports. and allows a multi technolgy multi segmented port caching"},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: I2473df267513c03ed864f8e8ac68d9734e6e56bd"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"ba5201f7_dc79d994","line":10,"range":{"start_line":10,"start_character":26,"end_line":10,"end_character":35},"updated":"2017-01-12 02:10:24.000000000","message":"technology","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":6598,"name":"Berezovsky Irena","email":"irenab.dev@gmail.com","username":"irenab"},"change_message_id":"d0bdf7a6b84287c6b1de3e117b939dae0ae818ad","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"LogicalNetworks is a common infra that holds different types of network"},{"line_number":10,"context_line":"ports. and allows a multi technolgy multi segmented port caching"},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: I2473df267513c03ed864f8e8ac68d9734e6e56bd"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"3a461143_f319e623","line":11,"updated":"2017-02-02 06:35:45.000000000","message":"missing link to bp/bug","commit_id":"ebdb1e069207e85fd71c9afc6068cad2c14d0246"},{"author":{"_account_id":24229,"name":"Igor Shafran","email":"igor.shafran@toganetworks.com","username":"ishafran"},"change_message_id":"a120ecbc509875ee17b1d825af7a0bd0c79090e4","unresolved":false,"context_lines":[{"line_number":7,"context_line":"logical_networks infra for network aware applications"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"LogicalNetworks is a common infra that holds different types of network"},{"line_number":10,"context_line":"ports. and allows a multi technolgy multi segmented port caching"},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Partially-Implements: bp Tunneling-app, bp Provider-networks-app"},{"line_number":13,"context_line":"Change-Id: I2473df267513c03ed864f8e8ac68d9734e6e56bd"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"fa31d9ce_6d16c656","line":10,"range":{"start_line":10,"start_character":26,"end_line":10,"end_character":35},"updated":"2017-02-12 12:22:37.000000000","message":"nit: technology","commit_id":"83d7131a5dd3e7d4bbb3fc837d3758b8bc29fc1f"}],"dragonflow/controller/common/logical_networks.py":[{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"936c6fea6a5f1b52ab8788814fecb1599213b943","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"ba5201f7_5cf7a9d2","updated":"2017-01-12 02:10:24.000000000","message":"If it is an app, it should not be inside the common folder.","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"ea3e2d8ea007490356c34c0762c37c62ecc2d8c6","unresolved":false,"context_lines":[{"line_number":17,"context_line":"import functools"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"class LogicalNetworks(object):"},{"line_number":21,"context_line":"    def __init__(self):"},{"line_number":22,"context_line":"        initialisor \u003d functools.partial(collections.defaultdict, list)"},{"line_number":23,"context_line":"        self.local_net \u003d collections.defaultdict(initialisor)"}],"source_content_type":"text/x-python","patch_set":1,"id":"7a3c09a3_c14ce972","line":20,"updated":"2017-01-15 09:35:19.000000000","message":"Missing docstring.","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"936c6fea6a5f1b52ab8788814fecb1599213b943","unresolved":false,"context_lines":[{"line_number":19,"context_line":""},{"line_number":20,"context_line":"class LogicalNetworks(object):"},{"line_number":21,"context_line":"    def __init__(self):"},{"line_number":22,"context_line":"        initialisor \u003d functools.partial(collections.defaultdict, list)"},{"line_number":23,"context_line":"        self.local_net \u003d collections.defaultdict(initialisor)"},{"line_number":24,"context_line":"        self.remote_net \u003d collections.defaultdict(initialisor)"},{"line_number":25,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ba5201f7_9c14b1e9","line":22,"range":{"start_line":22,"start_character":8,"end_line":22,"end_character":19},"updated":"2017-01-12 02:10:24.000000000","message":"initializer?","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"936c6fea6a5f1b52ab8788814fecb1599213b943","unresolved":false,"context_lines":[{"line_number":23,"context_line":"        self.local_net \u003d collections.defaultdict(initialisor)"},{"line_number":24,"context_line":"        self.remote_net \u003d collections.defaultdict(initialisor)"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"    def add_port(self, ports, port_id, network_id, network_type):"},{"line_number":27,"context_line":"        network_ports \u003d ports[network_id]"},{"line_number":28,"context_line":"        network_ports[network_type].append(port_id)"},{"line_number":29,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ba5201f7_dc8d5932","line":26,"range":{"start_line":26,"start_character":8,"end_line":26,"end_character":16},"updated":"2017-01-12 02:10:24.000000000","message":"mark this as private with a heading underline?","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"936c6fea6a5f1b52ab8788814fecb1599213b943","unresolved":false,"context_lines":[{"line_number":27,"context_line":"        network_ports \u003d ports[network_id]"},{"line_number":28,"context_line":"        network_ports[network_type].append(port_id)"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    def remove_port(self, ports, port_id, network_id, network_type):"},{"line_number":31,"context_line":"        network_ports \u003d ports.get(network_id)"},{"line_number":32,"context_line":"        if network_ports:"},{"line_number":33,"context_line":"            if port_id in network_ports[network_type]:"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba5201f7_fc7e9d19","line":30,"range":{"start_line":30,"start_character":8,"end_line":30,"end_character":19},"updated":"2017-01-12 02:10:24.000000000","message":"ditto","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"ea3e2d8ea007490356c34c0762c37c62ecc2d8c6","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"    def get_port_count(self, ports, network_id, network_type\u003dNone):"},{"line_number":37,"context_line":"        value \u003d 0"},{"line_number":38,"context_line":"        if ports.get(network_id):"},{"line_number":39,"context_line":"            if network_type:"},{"line_number":40,"context_line":"                value \u003d len(ports[network_id][network_type])"},{"line_number":41,"context_line":"            else:"}],"source_content_type":"text/x-python","patch_set":1,"id":"7a3c09a3_617255af","line":38,"range":{"start_line":38,"start_character":11,"end_line":38,"end_character":32},"updated":"2017-01-15 09:35:19.000000000","message":"Can be moved to a variable. Then it can be reused inside the if block.","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"936c6fea6a5f1b52ab8788814fecb1599213b943","unresolved":false,"context_lines":[{"line_number":55,"context_line":"                return ret_list"},{"line_number":56,"context_line":"        return None"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    def add_local_port(self, **kargs):"},{"line_number":59,"context_line":"        return self.add_port(self.local_net, **kargs)"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"    def add_remote_port(self, **kargs):"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba5201f7_7caaad72","line":58,"range":{"start_line":58,"start_character":4,"end_line":58,"end_character":38},"updated":"2017-01-12 02:10:24.000000000","message":"Can you show where would you use this method?","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"ea3e2d8ea007490356c34c0762c37c62ecc2d8c6","unresolved":false,"context_lines":[{"line_number":55,"context_line":"                return ret_list"},{"line_number":56,"context_line":"        return None"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    def add_local_port(self, **kargs):"},{"line_number":59,"context_line":"        return self.add_port(self.local_net, **kargs)"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"    def add_remote_port(self, **kargs):"}],"source_content_type":"text/x-python","patch_set":1,"id":"7a3c09a3_a1927d9d","line":58,"range":{"start_line":58,"start_character":4,"end_line":58,"end_character":38},"in_reply_to":"ba5201f7_7caaad72","updated":"2017-01-15 09:35:19.000000000","message":"These methods need a docstring. Especially due to the kwargs magic.","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":23766,"name":"Dima Kuznetsov","email":"dima.kuznetsov@toganetworks.com","username":"dimak"},"change_message_id":"463bcdac4244a5bcc940cace59070f6b57f1f538","unresolved":false,"context_lines":[{"line_number":19,"context_line":""},{"line_number":20,"context_line":"class LogicalNetworks(object):"},{"line_number":21,"context_line":"    def __init__(self):"},{"line_number":22,"context_line":"        initialisor \u003d functools.partial(collections.defaultdict, list)"},{"line_number":23,"context_line":"        self.local_net \u003d collections.defaultdict(initialisor)"},{"line_number":24,"context_line":"        self.remote_net \u003d collections.defaultdict(initialisor)"},{"line_number":25,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"5a3905b3_654cd89e","line":22,"range":{"start_line":22,"start_character":8,"end_line":22,"end_character":19},"updated":"2017-01-22 16:17:06.000000000","message":"initializer?","commit_id":"7d6f7b4566ac57d0d8c772c7756f3e8124909aa6"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"7780487f95a52911c9a9691bb488153da9cfef7f","unresolved":false,"context_lines":[{"line_number":49,"context_line":"            if network_type:"},{"line_number":50,"context_line":"                return network_ports[network_type]"},{"line_number":51,"context_line":"            else:"},{"line_number":52,"context_line":"                ret_list \u003d list()"},{"line_number":53,"context_line":"                for port_list in network_ports.values():"},{"line_number":54,"context_line":"                    ret_list +\u003d port_list"},{"line_number":55,"context_line":"                return ret_list"},{"line_number":56,"context_line":"        return None"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    def add_local_port(self, **kargs):"}],"source_content_type":"text/x-python","patch_set":2,"id":"5a3905b3_43c34f38","line":55,"range":{"start_line":52,"start_character":0,"end_line":55,"end_character":31},"updated":"2017-01-23 04:06:40.000000000","message":"Why not just return list(network_ports.values()) ?","commit_id":"7d6f7b4566ac57d0d8c772c7756f3e8124909aa6"},{"author":{"_account_id":23766,"name":"Dima Kuznetsov","email":"dima.kuznetsov@toganetworks.com","username":"dimak"},"change_message_id":"463bcdac4244a5bcc940cace59070f6b57f1f538","unresolved":false,"context_lines":[{"line_number":56,"context_line":"        return None"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    def add_local_port(self, **kargs):"},{"line_number":59,"context_line":"        return self._add_port(self.local_net, **kargs)"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"    def add_remote_port(self, **kargs):"},{"line_number":62,"context_line":"        return self._add_port(ports\u003dself.remote_net, **kargs)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5a3905b3_a53960f4","line":59,"range":{"start_line":59,"start_character":48,"end_line":59,"end_character":53},"updated":"2017-01-22 16:17:06.000000000","message":"kwargs","commit_id":"7d6f7b4566ac57d0d8c772c7756f3e8124909aa6"},{"author":{"_account_id":23766,"name":"Dima Kuznetsov","email":"dima.kuznetsov@toganetworks.com","username":"dimak"},"change_message_id":"463bcdac4244a5bcc940cace59070f6b57f1f538","unresolved":false,"context_lines":[{"line_number":56,"context_line":"        return None"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    def add_local_port(self, **kargs):"},{"line_number":59,"context_line":"        return self._add_port(self.local_net, **kargs)"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"    def add_remote_port(self, **kargs):"},{"line_number":62,"context_line":"        return self._add_port(ports\u003dself.remote_net, **kargs)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5a3905b3_25573027","line":59,"updated":"2017-01-22 16:17:06.000000000","message":"ports\u003d to be like other calls?\n\nEither-way, having **kwargs without docstring makes it hard to use the class, because help(LogicalNetworks.add_local_port) doesn\u0027t show what parameters it expects...","commit_id":"7d6f7b4566ac57d0d8c772c7756f3e8124909aa6"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"366dbecaf86218cb784f52192aa7ed670c4dd103","unresolved":false,"context_lines":[{"line_number":36,"context_line":"    def _get_port_count(self, ports, network_id, network_type):"},{"line_number":37,"context_line":"        value \u003d 0"},{"line_number":38,"context_line":"        if ports.get(network_id):"},{"line_number":39,"context_line":"            if network_type:"},{"line_number":40,"context_line":"                value \u003d len(ports[network_id][network_type])"},{"line_number":41,"context_line":"            else:"},{"line_number":42,"context_line":"                for port_list in ports[network_id].values():"},{"line_number":43,"context_line":"                    value +\u003d len(port_list)"}],"source_content_type":"text/x-python","patch_set":3,"id":"5a3905b3_f5d39a5d","line":40,"range":{"start_line":39,"start_character":0,"end_line":40,"end_character":60},"updated":"2017-01-25 02:07:59.000000000","message":"Is it possible that there are multiple network types under one network? I doubt that. But it is possible to have multiple l2 segments under one network, for example, vlan 1000 and vlan 1001 under one network. That is routed network. So if you want to add a key between network and port, I think it is better to be segment_id.","commit_id":"2c520e6e09492a33e8f7e501e14700c6db64606b"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"ed3db8efb6b203b2793fb74e998e7c4fad6e3bec","unresolved":false,"context_lines":[{"line_number":36,"context_line":"    def _get_port_count(self, ports, network_id, network_type):"},{"line_number":37,"context_line":"        value \u003d 0"},{"line_number":38,"context_line":"        if ports.get(network_id):"},{"line_number":39,"context_line":"            if network_type:"},{"line_number":40,"context_line":"                value \u003d len(ports[network_id][network_type])"},{"line_number":41,"context_line":"            else:"},{"line_number":42,"context_line":"                for port_list in ports[network_id].values():"},{"line_number":43,"context_line":"                    value +\u003d len(port_list)"}],"source_content_type":"text/x-python","patch_set":3,"id":"3a461143_443752b0","line":40,"range":{"start_line":39,"start_character":0,"end_line":40,"end_character":60},"in_reply_to":"5a3905b3_a548f288","updated":"2017-01-26 02:32:26.000000000","message":"Don\u0027t think about openstack, just a multi-segments network in real world. Is it more common to aggregate different network types together? or is it more common to aggregate same network type, but different segmentation ids, together? I think latter one is more common.\n\nAnd for openstack neutron, you can create one network with multi-segments by using neutron api now. But again, I don\u0027t think using network type here is reasonable. If you want to support multi-segments, using segmentation id here might be more appropriate. Or you can just remove network type here, and don\u0027t think about the multi-segments. It has not been supported in df now.","commit_id":"2c520e6e09492a33e8f7e501e14700c6db64606b"},{"author":{"_account_id":18347,"name":"Itamar Ofek","email":"itamofek@netscape.net","username":"itamaro"},"change_message_id":"eefb8359c5802fbdab98e8a3e6b51db08a7d570d","unresolved":false,"context_lines":[{"line_number":36,"context_line":"    def _get_port_count(self, ports, network_id, network_type):"},{"line_number":37,"context_line":"        value \u003d 0"},{"line_number":38,"context_line":"        if ports.get(network_id):"},{"line_number":39,"context_line":"            if network_type:"},{"line_number":40,"context_line":"                value \u003d len(ports[network_id][network_type])"},{"line_number":41,"context_line":"            else:"},{"line_number":42,"context_line":"                for port_list in ports[network_id].values():"},{"line_number":43,"context_line":"                    value +\u003d len(port_list)"}],"source_content_type":"text/x-python","patch_set":3,"id":"5a3905b3_a548f288","line":40,"range":{"start_line":39,"start_character":0,"end_line":40,"end_character":60},"in_reply_to":"5a3905b3_f5d39a5d","updated":"2017-01-25 09:59:43.000000000","message":"Right now in open stack you are correct. but this limitation is now enforced by the api. This however provide low level support for multi segmented network, with the same network id.","commit_id":"2c520e6e09492a33e8f7e501e14700c6db64606b"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"366dbecaf86218cb784f52192aa7ed670c4dd103","unresolved":false,"context_lines":[{"line_number":55,"context_line":"                return ret_list"},{"line_number":56,"context_line":"        return None"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    \"\"\" add local (on this compute host) logical port\"\"\""},{"line_number":59,"context_line":"    def add_local_port(self, port_id, network_id, network_type):"},{"line_number":60,"context_line":"        return self._add_port(ports\u003dself.local_net,"},{"line_number":61,"context_line":"                              port_id\u003dport_id,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5a3905b3_150e66e5","line":58,"range":{"start_line":58,"start_character":0,"end_line":58,"end_character":56},"updated":"2017-01-25 02:07:59.000000000","message":"pls move the docstring(this one and all the followings) into method and remove the heading space.","commit_id":"2c520e6e09492a33e8f7e501e14700c6db64606b"},{"author":{"_account_id":18347,"name":"Itamar Ofek","email":"itamofek@netscape.net","username":"itamaro"},"change_message_id":"eefb8359c5802fbdab98e8a3e6b51db08a7d570d","unresolved":false,"context_lines":[{"line_number":55,"context_line":"                return ret_list"},{"line_number":56,"context_line":"        return None"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    \"\"\" add local (on this compute host) logical port\"\"\""},{"line_number":59,"context_line":"    def add_local_port(self, port_id, network_id, network_type):"},{"line_number":60,"context_line":"        return self._add_port(ports\u003dself.local_net,"},{"line_number":61,"context_line":"                              port_id\u003dport_id,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5a3905b3_65352af6","line":58,"range":{"start_line":58,"start_character":0,"end_line":58,"end_character":56},"in_reply_to":"5a3905b3_150e66e5","updated":"2017-01-25 09:59:43.000000000","message":"OK","commit_id":"2c520e6e09492a33e8f7e501e14700c6db64606b"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"927890eef74056eed29f3cfd3c3281138c3fdb6a","unresolved":false,"context_lines":[{"line_number":17,"context_line":"import functools"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"class LogicalNetworks(object):"},{"line_number":21,"context_line":"    def __init__(self):"},{"line_number":22,"context_line":"        initialiser \u003d functools.partial(collections.defaultdict, list)"},{"line_number":23,"context_line":"        self.local_net \u003d collections.defaultdict(initialiser)"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a461143_4b544cc9","line":20,"updated":"2017-01-30 03:49:59.000000000","message":"Still missing docstring.","commit_id":"60360ade99b1abba5d03167529e33080eb73f2a4"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"927890eef74056eed29f3cfd3c3281138c3fdb6a","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"    def _get_port_count(self, ports, network_id, network_type):"},{"line_number":37,"context_line":"        value \u003d 0"},{"line_number":38,"context_line":"        if ports.get(network_id):"},{"line_number":39,"context_line":"            if network_type:"},{"line_number":40,"context_line":"                value \u003d len(ports[network_id][network_type])"},{"line_number":41,"context_line":"            else:"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a461143_8b60f4a6","line":38,"range":{"start_line":38,"start_character":11,"end_line":38,"end_character":32},"updated":"2017-01-30 03:49:59.000000000","message":"Still can be moved to a variable and reused.","commit_id":"60360ade99b1abba5d03167529e33080eb73f2a4"},{"author":{"_account_id":23766,"name":"Dima Kuznetsov","email":"dima.kuznetsov@toganetworks.com","username":"dimak"},"change_message_id":"a4d2a300a4d2af5c6e6fbdb0591a14e542717b0a","unresolved":false,"context_lines":[{"line_number":23,"context_line":"    ports. and allows a multi technolgy multi segmented port caching"},{"line_number":24,"context_line":"    \"\"\""},{"line_number":25,"context_line":"    def __init__(self):"},{"line_number":26,"context_line":"        initialiser \u003d functools.partial(collections.defaultdict, list)"},{"line_number":27,"context_line":"        self.local_net \u003d collections.defaultdict(initialiser)"},{"line_number":28,"context_line":"        self.remote_net \u003d collections.defaultdict(initialiser)"},{"line_number":29,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"3a461143_272805e2","line":26,"range":{"start_line":26,"start_character":8,"end_line":26,"end_character":19},"updated":"2017-01-30 13:43:18.000000000","message":"typo","commit_id":"e9d74bb58bed223b0e8d9bb30f7cbc20f2088ede"},{"author":{"_account_id":23766,"name":"Dima Kuznetsov","email":"dima.kuznetsov@toganetworks.com","username":"dimak"},"change_message_id":"a4d2a300a4d2af5c6e6fbdb0591a14e542717b0a","unresolved":false,"context_lines":[{"line_number":112,"context_line":"                               network_id\u003dnetwork_id,"},{"line_number":113,"context_line":"                               network_type\u003dnetwork_type)"},{"line_number":114,"context_line":""},{"line_number":115,"context_line":"    def get_remote_ports(self, network_id, network_type\u003dNone):"},{"line_number":116,"context_line":"        \"\"\"get all id\u0027s of remote ports belong to network  identified by"},{"line_number":117,"context_line":"           network_id, if type specified,  it will fetch only"},{"line_number":118,"context_line":"           ports according to type, otherwise all  ports are assembled"}],"source_content_type":"text/x-python","patch_set":9,"id":"3a461143_476c3135","line":115,"range":{"start_line":115,"start_character":43,"end_line":115,"end_character":55},"updated":"2017-01-30 13:43:18.000000000","message":"I think I am missing something about this, isn\u0027t network type determined by network id? Why do we need both?","commit_id":"e9d74bb58bed223b0e8d9bb30f7cbc20f2088ede"},{"author":{"_account_id":18347,"name":"Itamar Ofek","email":"itamofek@netscape.net","username":"itamaro"},"change_message_id":"4ee5b874d3ed915fae871edbeee5bb4a2dc71f7e","unresolved":false,"context_lines":[{"line_number":112,"context_line":"                               network_id\u003dnetwork_id,"},{"line_number":113,"context_line":"                               network_type\u003dnetwork_type)"},{"line_number":114,"context_line":""},{"line_number":115,"context_line":"    def get_remote_ports(self, network_id, network_type\u003dNone):"},{"line_number":116,"context_line":"        \"\"\"get all id\u0027s of remote ports belong to network  identified by"},{"line_number":117,"context_line":"           network_id, if type specified,  it will fetch only"},{"line_number":118,"context_line":"           ports according to type, otherwise all  ports are assembled"}],"source_content_type":"text/x-python","patch_set":9,"id":"3a461143_e57ed168","line":115,"range":{"start_line":115,"start_character":43,"end_line":115,"end_character":55},"in_reply_to":"3a461143_476c3135","updated":"2017-01-31 11:25:07.000000000","message":"It may support same network id with different types (not supported by openstack). i.e both vxlan and vpn part of the same network.","commit_id":"e9d74bb58bed223b0e8d9bb30f7cbc20f2088ede"},{"author":{"_account_id":6598,"name":"Berezovsky Irena","email":"irenab.dev@gmail.com","username":"irenab"},"change_message_id":"6131686d7bf3e219df3002596a9295e5fd7718c5","unresolved":false,"context_lines":[{"line_number":20,"context_line":"class LogicalNetworks(object):"},{"line_number":21,"context_line":"    \"\"\""},{"line_number":22,"context_line":"    LogicalNetworks is a common infra that holds different types of network"},{"line_number":23,"context_line":"    ports. and allows a multi technolgy multi segmented port caching"},{"line_number":24,"context_line":"    \"\"\""},{"line_number":25,"context_line":"    def __init__(self):"},{"line_number":26,"context_line":"        initializer \u003d functools.partial(collections.defaultdict, list)"}],"source_content_type":"text/x-python","patch_set":21,"id":"fa31d9ce_8a04b2c0","line":23,"range":{"start_line":23,"start_character":24,"end_line":23,"end_character":60},"updated":"2017-02-13 06:15:23.000000000","message":"what is this?","commit_id":"83d7131a5dd3e7d4bbb3fc837d3758b8bc29fc1f"},{"author":{"_account_id":6598,"name":"Berezovsky Irena","email":"irenab.dev@gmail.com","username":"irenab"},"change_message_id":"6131686d7bf3e219df3002596a9295e5fd7718c5","unresolved":false,"context_lines":[{"line_number":21,"context_line":"    \"\"\""},{"line_number":22,"context_line":"    LogicalNetworks is a common infra that holds different types of network"},{"line_number":23,"context_line":"    ports. and allows a multi technolgy multi segmented port caching"},{"line_number":24,"context_line":"    \"\"\""},{"line_number":25,"context_line":"    def __init__(self):"},{"line_number":26,"context_line":"        initializer \u003d functools.partial(collections.defaultdict, list)"},{"line_number":27,"context_line":"        self.local_net \u003d collections.defaultdict(initializer)"}],"source_content_type":"text/x-python","patch_set":21,"id":"fa31d9ce_0ab522ed","line":24,"range":{"start_line":24,"start_character":4,"end_line":24,"end_character":7},"updated":"2017-02-13 06:15:23.000000000","message":"worth to add note on the structure of the local cache (what is kept as key, val)","commit_id":"83d7131a5dd3e7d4bbb3fc837d3758b8bc29fc1f"},{"author":{"_account_id":6598,"name":"Berezovsky Irena","email":"irenab.dev@gmail.com","username":"irenab"},"change_message_id":"6131686d7bf3e219df3002596a9295e5fd7718c5","unresolved":false,"context_lines":[{"line_number":24,"context_line":"    \"\"\""},{"line_number":25,"context_line":"    def __init__(self):"},{"line_number":26,"context_line":"        initializer \u003d functools.partial(collections.defaultdict, list)"},{"line_number":27,"context_line":"        self.local_net \u003d collections.defaultdict(initializer)"},{"line_number":28,"context_line":"        self.remote_net \u003d collections.defaultdict(initializer)"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    def _add_port(self, ports, port_id, network_id, network_type):"}],"source_content_type":"text/x-python","patch_set":21,"id":"fa31d9ce_eabd2ed8","line":27,"range":{"start_line":27,"start_character":7,"end_line":27,"end_character":22},"updated":"2017-02-13 06:15:23.000000000","message":"the name is confusing, better something like local_ports_net_cache","commit_id":"83d7131a5dd3e7d4bbb3fc837d3758b8bc29fc1f"},{"author":{"_account_id":6598,"name":"Berezovsky Irena","email":"irenab.dev@gmail.com","username":"irenab"},"change_message_id":"6131686d7bf3e219df3002596a9295e5fd7718c5","unresolved":false,"context_lines":[{"line_number":37,"context_line":"            if port_id in network_ports[network_type]:"},{"line_number":38,"context_line":"                network_ports[network_type].remove(port_id)"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    def _get_port_count(self, ports, network_id, network_type):"},{"line_number":41,"context_line":"        value \u003d 0"},{"line_number":42,"context_line":"        network_ports \u003d ports.get(network_id)"},{"line_number":43,"context_line":"        if network_ports:"}],"source_content_type":"text/x-python","patch_set":21,"id":"fa31d9ce_4a21da4c","line":40,"range":{"start_line":40,"start_character":48,"end_line":40,"end_character":62},"updated":"2017-02-13 06:15:23.000000000","message":"can be \u0027Non\u0027 by defualt","commit_id":"83d7131a5dd3e7d4bbb3fc837d3758b8bc29fc1f"},{"author":{"_account_id":6598,"name":"Berezovsky Irena","email":"irenab.dev@gmail.com","username":"irenab"},"change_message_id":"6131686d7bf3e219df3002596a9295e5fd7718c5","unresolved":false,"context_lines":[{"line_number":48,"context_line":"                    value +\u003d len(port_list)"},{"line_number":49,"context_line":"        return value"},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"    def _get_ports(self, ports, network_id, network_type):"},{"line_number":52,"context_line":"        network_ports \u003d ports.get(network_id)"},{"line_number":53,"context_line":"        if network_ports:"},{"line_number":54,"context_line":"            if network_type:"}],"source_content_type":"text/x-python","patch_set":21,"id":"fa31d9ce_aa16d6ee","line":51,"range":{"start_line":51,"start_character":44,"end_line":51,"end_character":57},"updated":"2017-02-13 06:15:23.000000000","message":"ditto","commit_id":"83d7131a5dd3e7d4bbb3fc837d3758b8bc29fc1f"}],"dragonflow/tests/unit/test_classifier_app.py":[{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"936c6fea6a5f1b52ab8788814fecb1599213b943","unresolved":false,"context_lines":[{"line_number":13,"context_line":"#    License for the specific language governing permissions and limitations"},{"line_number":14,"context_line":"#    under the License."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"#import copy"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from dragonflow.controller.common import constants as const"},{"line_number":19,"context_line":"from dragonflow.db import models as db_models"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba5201f7_dc6399af","line":16,"range":{"start_line":16,"start_character":0,"end_line":16,"end_character":12},"updated":"2017-01-12 02:10:24.000000000","message":"This should be removed.","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"936c6fea6a5f1b52ab8788814fecb1599213b943","unresolved":false,"context_lines":[{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from dragonflow.controller.common import constants as const"},{"line_number":19,"context_line":"from dragonflow.db import models as db_models"},{"line_number":20,"context_line":"from dragonflow.tests.unit.test_app_base import DFAppTestBase"},{"line_number":21,"context_line":"from dragonflow.tests.unit.test_app_base import make_fake_local_port"},{"line_number":22,"context_line":"from dragonflow.tests.unit.test_app_base import make_fake_logic_switch"},{"line_number":23,"context_line":"import mock"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ba5201f7_7c69cd8b","line":22,"range":{"start_line":20,"start_character":0,"end_line":22,"end_character":70},"updated":"2017-01-12 02:10:24.000000000","message":"You should import module instead of import class or functions.","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":11159,"name":"Hong Hui Xiao","email":"honghui_xiao@yeah.net","username":"HongHuiXiao"},"change_message_id":"936c6fea6a5f1b52ab8788814fecb1599213b943","unresolved":false,"context_lines":[{"line_number":20,"context_line":"from dragonflow.tests.unit.test_app_base import DFAppTestBase"},{"line_number":21,"context_line":"from dragonflow.tests.unit.test_app_base import make_fake_local_port"},{"line_number":22,"context_line":"from dragonflow.tests.unit.test_app_base import make_fake_logic_switch"},{"line_number":23,"context_line":"import mock"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"class TestClassifierApp(DFAppTestBase):"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba5201f7_7c52addf","line":23,"range":{"start_line":23,"start_character":0,"end_line":23,"end_character":11},"updated":"2017-01-12 02:10:24.000000000","message":"This import should go before import dragonflow.*","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"ea3e2d8ea007490356c34c0762c37c62ecc2d8c6","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        fake_local_vlan_port \u003d make_fake_local_port(network_type\u003d\u0027vlan\u0027,"},{"line_number":41,"context_line":"                lswitch\u003d\u0027fake_vlan_switch1\u0027)"},{"line_number":42,"context_line":"        network_type \u003d fake_local_vlan_port.get_external_value(\u0027network_type\u0027)"},{"line_number":43,"context_line":"        print \"test network type \u003d %s\" % network_type"},{"line_number":44,"context_line":"        self.controller.update_lport(fake_local_vlan_port)"},{"line_number":45,"context_line":"        network_type \u003d fake_local_vlan_port.get_external_value(\u0027network_type\u0027)"},{"line_number":46,"context_line":"        print \"test network type \u003d %s\" % network_type"}],"source_content_type":"text/x-python","patch_set":1,"id":"7a3c09a3_61f7b5f5","line":43,"range":{"start_line":43,"start_character":0,"end_line":43,"end_character":53},"updated":"2017-01-15 09:35:19.000000000","message":"Please use the logging framework, instead of print, and please invoke print in a py3 compliant manner.","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"ea3e2d8ea007490356c34c0762c37c62ecc2d8c6","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        print \"test network type \u003d %s\" % network_type"},{"line_number":44,"context_line":"        self.controller.update_lport(fake_local_vlan_port)"},{"line_number":45,"context_line":"        network_type \u003d fake_local_vlan_port.get_external_value(\u0027network_type\u0027)"},{"line_number":46,"context_line":"        print \"test network type \u003d %s\" % network_type"},{"line_number":47,"context_line":"        self.app.mod_flow.assert_called_with("},{"line_number":48,"context_line":"            datapath\u003dself.app.get_datapath(),"},{"line_number":49,"context_line":"            inst\u003dmock.ANY,"}],"source_content_type":"text/x-python","patch_set":1,"id":"7a3c09a3_81de616b","line":46,"updated":"2017-01-15 09:35:19.000000000","message":"Same here.","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"ea3e2d8ea007490356c34c0762c37c62ecc2d8c6","unresolved":false,"context_lines":[{"line_number":56,"context_line":"        fake_local_vlan_port \u003d make_fake_local_port(network_type\u003d\u0027flat\u0027,"},{"line_number":57,"context_line":"                lswitch\u003d\u0027fake_flat_switch1\u0027)"},{"line_number":58,"context_line":"        network_type \u003d fake_local_vlan_port.get_external_value(\u0027network_type\u0027)"},{"line_number":59,"context_line":"        print \"test network type \u003d %s\" % network_type"},{"line_number":60,"context_line":"        self.controller.update_lport(fake_local_vlan_port)"},{"line_number":61,"context_line":"        network_type \u003d fake_local_vlan_port.get_external_value(\u0027network_type\u0027)"},{"line_number":62,"context_line":"        print \"test network type \u003d %s\" % network_type"}],"source_content_type":"text/x-python","patch_set":1,"id":"7a3c09a3_a1d99d85","line":59,"updated":"2017-01-15 09:35:19.000000000","message":"And here","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"ea3e2d8ea007490356c34c0762c37c62ecc2d8c6","unresolved":false,"context_lines":[{"line_number":59,"context_line":"        print \"test network type \u003d %s\" % network_type"},{"line_number":60,"context_line":"        self.controller.update_lport(fake_local_vlan_port)"},{"line_number":61,"context_line":"        network_type \u003d fake_local_vlan_port.get_external_value(\u0027network_type\u0027)"},{"line_number":62,"context_line":"        print \"test network type \u003d %s\" % network_type"},{"line_number":63,"context_line":"        self.app.mod_flow.assert_called_with("},{"line_number":64,"context_line":"            datapath\u003dself.app.get_datapath(),"},{"line_number":65,"context_line":"            inst\u003dmock.ANY,"}],"source_content_type":"text/x-python","patch_set":1,"id":"7a3c09a3_e1e3a531","line":62,"updated":"2017-01-15 09:35:19.000000000","message":"And here","commit_id":"553f3299a557b468551653a36f198a8c8aae5691"}],"dragonflow/tests/unit/test_logical_networks.py":[{"author":{"_account_id":23766,"name":"Dima Kuznetsov","email":"dima.kuznetsov@toganetworks.com","username":"dimak"},"change_message_id":"a5edc53c7c76c1bd94e8ae3fdadfc1a182a54eff","unresolved":false,"context_lines":[{"line_number":23,"context_line":"        self.logical_networks \u003d logical_networks.LogicalNetworks()"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"    def test_add_remove_local_port(self):"},{"line_number":26,"context_line":"        fake_local_vlan_port1 \u003d test_app_base.make_fake_local_port("},{"line_number":27,"context_line":"                network_type\u003d\u0027vlan\u0027,"},{"line_number":28,"context_line":"                name\u003d\u0027fake_local_vlan_port1\u0027,"},{"line_number":29,"context_line":"                unique_key\u003d3,"},{"line_number":30,"context_line":"                ofport\u003d2,"},{"line_number":31,"context_line":"                lswitch\u003d\u0027fake_vlan_switch1\u0027,"},{"line_number":32,"context_line":"                local_network_id\u003d1)"},{"line_number":33,"context_line":"        self.logical_networks.add_local_port("},{"line_number":34,"context_line":"                port_id\u003dfake_local_vlan_port1.get_id(),"},{"line_number":35,"context_line":"                network_id\u003d1,"}],"source_content_type":"text/x-python","patch_set":24,"id":"fa31d9ce_3c22ed52","line":32,"range":{"start_line":26,"start_character":0,"end_line":32,"end_character":35},"updated":"2017-02-14 13:14:05.000000000","message":"nit: Since the actual port is not used (just the ID), creating it is a bit redundant\n\n(applies below too)","commit_id":"32c2bbf4fc8a3a25a1222e0eaf89b16f829ebbd6"}]}
