wfgydbu edited a comment on issue #2520:
URL: https://github.com/apache/apisix/issues/2520#issuecomment-719110566


   > It seems that when check the schema of Routes, APISIX tries to fetch the 
schema firstly and compile it, the compilation result will be cached inside a 
LRU cache. The schema creation is exclusive by a Lock. But the creation is 
totally compution and without IO operations, the default timeout for lock:lock 
is 5s, which is almost impossible to be timed out.
   > 
   > @membphis
   
   I've been digging into related code these days.  It looks to me that this 
logic is right. 
   
   I've tested with 32 woker processes by each process having 7 light threads, 
in this situation, one of the 7 threads used to deal with the key 
`/apisix/route` containg only one route(`apisix/route/1`).
   
   My question are: 
   (1) It it safe to simply increase the default timeout value from 5 to 10 
likely? if not, what cost we would have (i.e. performance reduction)? 
   (2) What will happen when one route fail to be synced from etcd. Will it be 
synced (successfully this time) again in the next iteration?
   
   @membphis @spacewander @tokers Anything will be appreciated.
   
   


----------------------------------------------------------------
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.

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


Reply via email to