)]}'
{"astara/drivers/router.py":[{"author":{"_account_id":2592,"name":"Mark McClain","email":"mark@mcclain.xyz","username":"markmcclain"},"change_message_id":"ab5b5f987a1929781a61c16ed44a83e024f3c196","unresolved":false,"context_lines":[{"line_number":80,"context_line":"DRIVER_NAME \u003d \u0027router\u0027"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"def ensure_cache(f):"},{"line_number":84,"context_line":"    \"\"\"Decorator to wrap around any function that uses self._router.\"\"\""},{"line_number":85,"context_line":"    def wrapper(self, worker_context, *args, **kw):"},{"line_number":86,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":3,"id":"da6ed579_400b598e","line":83,"updated":"2016-01-14 18:12:56.000000000","message":"Can we update this to use functools.wraps()? [1]\n\n[1] https://docs.python.org/2/library/functools.html#functools.wraps","commit_id":"813febf2e5f814891c8c66225af23740da9b40cb"},{"author":{"_account_id":2592,"name":"Mark McClain","email":"mark@mcclain.xyz","username":"markmcclain"},"change_message_id":"67ca0b3ff653163c88e2c12f49889841f50699a1","unresolved":false,"context_lines":[{"line_number":187,"context_line":"                self._router)"},{"line_number":188,"context_line":"            self._router.external_port \u003d ext_port"},{"line_number":189,"context_line":""},{"line_number":190,"context_line":"    @ensure_cache"},{"line_number":191,"context_line":"    def make_ports(self, worker_context):"},{"line_number":192,"context_line":"        \"\"\"make ports call back for the nova client."},{"line_number":193,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"5a5ae5dd_625d5814","line":190,"updated":"2016-02-05 16:39:37.000000000","message":"Same issue as load balancer change.  The decorator should be applied to the inner method to ensure the cache is current.","commit_id":"a915abfe6c82e8807766b3cc2ab3867ef1e07e85"},{"author":{"_account_id":19133,"name":"Yang Hongyang","email":"hongyang.yang@easystack.cn","username":"macrosheep"},"change_message_id":"ac51ab01443c4dae41ed5e5255e34fd3a85b566b","unresolved":false,"context_lines":[{"line_number":187,"context_line":"                self._router)"},{"line_number":188,"context_line":"            self._router.external_port \u003d ext_port"},{"line_number":189,"context_line":""},{"line_number":190,"context_line":"    @ensure_cache"},{"line_number":191,"context_line":"    def make_ports(self, worker_context):"},{"line_number":192,"context_line":"        \"\"\"make ports call back for the nova client."},{"line_number":193,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"5a5ae5dd_f696dc3c","line":190,"in_reply_to":"5a5ae5dd_625d5814","updated":"2016-02-06 02:26:08.000000000","message":"Hi mark, thanks for review, there\u0027s a problem that we can not decorate the inner function, the decorated function should take at least \u0027worker_context\u0027 as a parameter, but _make_ports do not have the param. After dig with it, I can\u0027t find a way to refactor ensure_cache for this api, so I think I will drop this patch as well as the load balancer change. Do you have a better idea about this?","commit_id":"a915abfe6c82e8807766b3cc2ab3867ef1e07e85"}]}
