-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Operation timeouts do not work as expected #119
Comments
If I understand correctly, you are delaying the callback. The timeout is for the actual Memcache operation, not what you do with the result. |
The error callback is not being intentionally delayed in any way. The "main" Here is another example. From the output it can be seen that a new "GET"
|
I totally misread your example yesterday, sorry, I must have been tired. You are right, the timeout do not work as they should in your example. It seems like each new request cancels the timeout of the previous one. My initial guess is that it has something to do with the connection setup logic (there are some calls to cancel timeouts in there). This would mean the timeout work as intended once a connection is established successfully. I will dig some more to see why this happens exactly. |
I've written a small program to demonstrate the problem:
It configures the client's timeout to 1 second and then performs an operation
every 0.5 seconds, each of which is expected to time out.
From the output it's clearly visible that the operations did not time out after
1 second, as was expected. Instead, every new operation caused the previous
one's timeout timer to be reset.
If I keep sending a steady stream of operations every 0.5 seconds, then
none of them will ever time out and the callbacks will be left hanging forever.
The text was updated successfully, but these errors were encountered: