karlchan-cn opened a new pull request, #411:
URL: https://github.com/apache/httpcomponents-core/pull/411

   Hello,
   
   I suggest that leasing a connection should be done no more than the 
designated request-time-out which is provided by the user.
   
   And besides, beneath the method 
```org.apache.http.nio.pool.AbstractNIOConnPool.processPendingRequest```
   there are some sorta time-consuming actions like below.
   
   
![image](https://github.com/apache/httpcomponents-core/assets/3454327/85280bf4-1a88-4350-be97-70fc244451c4)
   
   Let's say the request-time-out of setting is ### 10ms and the 
```this.lock.lock()``` takes about ### 15ms to acquire a permission to lease.
   I recommend here we should try to lock with a timeout setting.
   
   I hope this modification could help improve the logic and make me contribute 
a bit here.
   
   Looking forward for your replay. Thanks.
   


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to