From d95500948d0af71bb6a378b9634d57b984c6e78c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=BD=97=E6=B3=BD=E8=BD=A9?= Date: Mon, 16 May 2022 14:52:24 +0800 Subject: [PATCH] fix(xRPC): release ctx.var when ctx is done (#7045) Signed-off-by: spacewander --- apisix/stream/xrpc/runner.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/apisix/stream/xrpc/runner.lua b/apisix/stream/xrpc/runner.lua index 8c082a1966af..51dbd271e338 100644 --- a/apisix/stream/xrpc/runner.lua +++ b/apisix/stream/xrpc/runner.lua @@ -50,6 +50,8 @@ local function put_req_ctx(session, ctx) local id = ctx._id session._ctxs[id] = nil + core.ctx.release_vars(ctx) + core.tablepool.release("xrpc_ctxs", ctx) end