channer99 opened a new issue, #10392:
URL: https://github.com/apache/apisix/issues/10392

   ### Description
   
   A tendency for memory to gradually increase was confirmed.
   checking many issues related to memory(prometheus, ext-plugin, etc...), but 
i cannot determine the exact cause.
   
   <img width="1127" alt="1_memory_trand" 
src="https://github.com/apache/apisix/assets/148939043/7d50b388-1f3e-4182-8cd8-44195f648145";>
   
   The plugin below is used as a global plugin.
   - cors, opentelemetry, prometheus, request_id, response_rewrite
   The following plugins were set for individual routes.
   - elasticsearch-logger, ext-plugin-pre-req, limit-count
   
   So I obtained a flamegraph through openresty xray. 
   Can you check where the memory leak occurs?
   
   ![2_Lua-Land Memory Leak Flame 
Graphs](https://github.com/apache/apisix/assets/148939043/b5ffcb14-cdea-4ecf-894a-6488149c29eb)
   ![3_LuaJIT GC Object Allocation Flame 
Graph](https://github.com/apache/apisix/assets/148939043/57ef3eb6-fb5c-4dd3-914f-e93bc01b4ed5)
   ![4_LuaJIT GC Object Allocation Size Flame 
Graph](https://github.com/apache/apisix/assets/148939043/33a39f4f-0c95-4147-9c8d-11a2fb7e2912)
   ![5_LuaJIT String Objects Allocation Flame 
Graph](https://github.com/apache/apisix/assets/148939043/c9e8e051-ed79-462c-8491-ba0bad478c08)
   ![6_LuaJIT Table Objects Allocation Flame 
Graph](https://github.com/apache/apisix/assets/148939043/406c3be3-4854-483f-96b0-2a290444405b)
   ![7_Lua Memory Realloc Size 
Flamegraphs](https://github.com/apache/apisix/assets/148939043/eabc4e07-a5bd-4fcb-96e1-731a598e4386)
   ![8_GC Object Reference Flame 
Graph](https://github.com/apache/apisix/assets/148939043/446898eb-7515-44da-89f3-32e8bd984b4c)
   <img width="582" alt="9_Application-Level Memory Usage Breakdown_10_25" 
src="https://github.com/apache/apisix/assets/148939043/f154bfdf-50b1-4477-b8ab-3ba073334ff7";>
   <img width="618" alt="10_Application-Level Memory Usage Breakdown_10_23 png" 
src="https://github.com/apache/apisix/assets/148939043/de1f0d15-baa6-499b-8274-8e30c240a1c5";>
   
   It cannot be used in the operating environment due to memory increase issues.
   need another analyzer(openresty xray) to accurately identify this issues? 
Please advise.
   
   ### Environment
   
   - APISIX version (run `apisix version`): 3.4.1
   - Operating system (run `uname -a`): Linux 5.4.0-147-generic
   - OpenResty / Nginx version (run `openresty -V` or `nginx -V`): 
openresty/1.21.4.2
   - etcd version, if relevant (run `curl 
http://127.0.0.1:9090/v1/server_info`): 3.5.0
   - APISIX Dashboard version, if relevant: 3.0.1
   - Plugin runner version, for issues related to plugin runners:
   - LuaRocks version, for installation issues (run `luarocks --version`): 3.8.0
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to