You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2022/06/20 03:25:36 UTC

[GitHub] [apisix] tzssangglass commented on issue #7258: bug: read header may cause an abnormally high CPU

tzssangglass commented on issue #7258:
URL: https://github.com/apache/apisix/issues/7258#issuecomment-1159926758

   > It seems that there isn't necessary to call it here, what about changing it to this?
   
   It's a question of balance.
   
   case 1: If the request gets only one header here in APISIX, then it is fastest to get it directly.
   
   case 2: If the request gets other headers in other plugins or features of APISIX then caching the headers is better.
   Because `ctx.var.http_x_forwarded_proto` reads variables directly from C land to Lua land, which is slower than fetching from the cache.


-- 
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: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org