sshniro commented on issue #1189: request help: How to implement thread sleep in Nginx Test URL: https://github.com/apache/incubator-apisix/issues/1189#issuecomment-594379479 I would like to write a test case to test the inactive timeout. The following are the configurations. - Inactive Timeout = 2 S - Batch Max Size = 100  I would like to push an entry to the buffer at 0s and wait till 2s and push another entry. In this manner, I can reach the line segment of the code block[extending buffer timer]. To achieve this I need to wait for 2s before pushing the next entry to the buffer in the test case. I've tried this solution but unfortunately, it does not work as expected. ```lua require "socket" function sleep(sec) socket.select(nil, nil, sec) end sleep(2) ```
---------------------------------------------------------------- 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] With regards, Apache Git Services
