-
Notifications
You must be signed in to change notification settings - Fork 382
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
param: New deadline_pipe parameter #4043
Conversation
bugwash:
|
I don't think the last commit can go in without a review. |
My homework submission after bugwash discussion: In preparation of addition of a new So, with respect to this PR, I think that:
*1) and then we come back to the question of whether pipe is client or backend 😵💫 |
As of today, no question, pipe is client 😁 So to summarize the VCL control you want:
Correct me if I'm wrong with the above. Since |
Of course the moment I submit the comment a thought occurs to me. In
So in pipe mode we may override a client deadline independently. I think task deadlines should remain independent because if a backend fetch is too slow for a client request, it should be allowed to proceed in the absence of a bereq deadline since it may also service other client requests with different deadlines or none at all (waiting list hits, hits during streaming etc). It's also simpler to not have those relationships, a win on both sides. |
@dridi 👏🏽 I fully agree with your proposed design with respect to the pipe deadline. You also convinced me to make the bereq timeout independent, but we need to consider these aspects:
But I still think that subordinate (ESI) req timeouts need to be bound hierarchically. |
Apologies for the accidental close |
I agree, sub-requests are effectively sub-tasks. |
This takes care of documenting the meaning of a zero timeout value in a central location, since none of the timeout parameters have a mention for the effect it produces. This is written as if there was a separate varnish-param(7) manual, which should eventually be enacted. This manual extraction was initially implemented in the adjacent varnishcache#3817 timeout nomenclature draft.
The [be]req.task_deadline should eventually be generalized to all subroutines with read-write access to [be]req. When that happens, bereq.task_deadline will inherit req.task_deadline during the pipe transition. Related tasks should otherwise have independent deadlines, except sub-request tasks like ESI where there is a hierarchical dependency.
I am confident now that the last rebase-force-push meets the bugwash "push it when it's ready" criteria. I'll wait (for CI and) until the end of my business day before merging. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM from 👀
Otherwise poll(2) returns EINVAL on FreeBSD when both pipe_timeout and pipe_task_deadline are disabled. Fixes varnishcache#4043
Otherwise poll(2) returns EINVAL on FreeBSD when both pipe_timeout and pipe_task_deadline are disabled. Fixes varnishcache#4043
Otherwise poll(2) returns EINVAL on FreeBSD when both pipe_timeout and pipe_task_deadline are disabled. Fixes varnishcache#4043
The other timeouts should eventually become unset-able as well, where an unset variable falls back to a parameter and zero means no timeout, overriding the fallback parameter. Refs #4043
For reference, the following was added afterwards:
|
Otherwise poll(2) returns EINVAL on FreeBSD when both pipe_timeout and pipe_task_deadline are disabled. Fixes varnishcache#4043
Otherwise poll(2) returns EINVAL on FreeBSD when both pipe_timeout and pipe_task_deadline are disabled. Fixes #4043
Followup from the last VDD, the idea of having deadlines was discussed.
This patch series fixes a bug, improves logging slightly, and introduces a new
deadline_pipe
parameter. It leavesdeadline_client
anddeadline_backend
for later as this is the simplest to implement among the three.The parameter is disabled by default to match the current behavior.