)]}'
{"os_ken/services/protocols/bgp/base.py":[{"author":{"_account_id":4187,"name":"Ryan Tidwell","email":"rtidwell@suse.com","username":"ryan-tidwell"},"change_message_id":"38220974d2ba92a7ffd17089ae9ab563fdfb730a","unresolved":false,"context_lines":[{"line_number":310,"context_line":"        Re-initializes this activity to be able to start again. If the activity"},{"line_number":311,"context_line":"        is not started (is already stopped), it will silently return."},{"line_number":312,"context_line":"        \"\"\""},{"line_number":313,"context_line":"        if not self.started:"},{"line_number":314,"context_line":"            return"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"        LOG.debug(\u0027Stopping activity %s.\u0027, self.name)"},{"line_number":317,"context_line":"        self._stop_timers()"}],"source_content_type":"text/x-python","patch_set":1,"id":"5fc1f717_117cf0e9","line":314,"range":{"start_line":313,"start_character":8,"end_line":314,"end_character":18},"updated":"2019-04-01 15:55:51.000000000","message":"This seemed like the obvious fix to me as well. I wonder if there are any side-effects to this. It doesn\u0027t seem like it to me, but my depth with ryu/os-ken really ends at the API level so I could be missing something that others with more depth in these libraries would spot.\n\nWould it be worth it to add a test to get some coverage on this?","commit_id":"7cab51acdbe6ae99927279cf1b879519d89de17c"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"71c498365f1ed9283cbfa9aa7f9e7f6aa0528b81","unresolved":false,"context_lines":[{"line_number":310,"context_line":"        Re-initializes this activity to be able to start again. If the activity"},{"line_number":311,"context_line":"        is not started (is already stopped), it will silently return."},{"line_number":312,"context_line":"        \"\"\""},{"line_number":313,"context_line":"        if not self.started:"},{"line_number":314,"context_line":"            return"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"        LOG.debug(\u0027Stopping activity %s.\u0027, self.name)"},{"line_number":317,"context_line":"        self._stop_timers()"}],"source_content_type":"text/x-python","patch_set":1,"id":"5fc1f717_647483d1","line":314,"range":{"start_line":313,"start_character":8,"end_line":314,"end_character":18},"in_reply_to":"5fc1f717_117cf0e9","updated":"2019-04-02 09:35:03.000000000","message":"The problem is the skinny unit/functional test framework existent in this project; to test this properly we need to implement new test classes.\n\nLet me write down where this is affecting.\n\nclass Activity is being inherited in BMPCLient, _CoreManager, RpcSession and BgpProcessor.\n\n_CoreManager: when stop() is called [1], first is checked if the process is started. In the negative case, a specific exception is risen. This change won\u0027t affect.\n\nRPCSession: the RPC session is stored in _NetworkController as a child activity [2]. When those child activities are stopped [3], we first check if child.started is True. This change won\u0027t affect.\n\nBgpProcessor: same as RPCSession. Is treated as a child activity [4].\n\nBMPClient: this where this patch is affecting. A BMP client is stopped in [5]. IMO, and that\u0027s why I submit this patch, if the client is already stopped, why should not raise an exception but exit the function and return. Activity.stop should be idempotent; we should be able to call it several times with the same result: the Actitivy object stopped.\n\n\n[1] https://github.com/openstack/os-ken/blob/master/os_ken/services/protocols/bgp/api/core.py#L56-L60\n[2] https://github.com/openstack/os-ken/blob/master/os_ken/services/protocols/bgp/net_ctrl.py#L370-L377\n[3] https://github.com/openstack/os-ken/blob/master/os_ken/services/protocols/bgp/base.py#L271-L282\n[4] https://github.com/openstack/os-ken/blob/master/os_ken/services/protocols/bgp/core.py#L219-L221\n[5] https://github.com/openstack/os-ken/blob/master/os_ken/services/protocols/bgp/core.py#L484-L490","commit_id":"7cab51acdbe6ae99927279cf1b879519d89de17c"}]}
