Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
9aa7fae2
Commit
9aa7fae2
authored
May 17, 2021
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Busyobj->do_pass was surplus to requirements, ->uncacheable is plenty.
parent
1adbf27d
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
9 deletions
+9
-9
cache_fetch.c
bin/varnishd/cache/cache_fetch.c
+6
-7
cache_req_fsm.c
bin/varnishd/cache/cache_req_fsm.c
+2
-0
cache_vrt_var.c
bin/varnishd/cache/cache_vrt_var.c
+1
-1
bo_flags.h
include/tbl/bo_flags.h
+0
-1
No files found.
bin/varnishd/cache/cache_fetch.c
View file @
9aa7fae2
...
...
@@ -259,9 +259,9 @@ vbf_stp_mkbereq(struct worker *wrk, struct busyobj *bo)
HTTP_Setup
(
bo
->
bereq0
,
bo
->
ws
,
bo
->
vsl
,
SLT_BereqMethod
);
http_FilterReq
(
bo
->
bereq0
,
bo
->
req
->
http
,
bo
->
do_pass
?
HTTPH_R_PASS
:
HTTPH_R_FETCH
);
bo
->
uncacheable
?
HTTPH_R_PASS
:
HTTPH_R_FETCH
);
if
(
bo
->
do_pass
)
if
(
bo
->
uncacheable
)
AZ
(
bo
->
stale_oc
);
else
{
http_ForceField
(
bo
->
bereq0
,
HTTP_HDR_METHOD
,
"GET"
);
...
...
@@ -366,7 +366,7 @@ vbf_304_logic(struct busyobj *bo)
HTTP_Merge
(
bo
->
wrk
,
bo
->
stale_oc
,
bo
->
beresp
);
assert
(
http_IsStatus
(
bo
->
beresp
,
200
));
bo
->
was_304
=
1
;
}
else
if
(
!
bo
->
do_pass
)
{
}
else
if
(
!
bo
->
uncacheable
)
{
/*
* Backend sent unallowed 304
*/
...
...
@@ -397,7 +397,7 @@ vbf_stp_startfetch(struct worker *wrk, struct busyobj *bo)
CHECK_OBJ_NOTNULL
(
oc
,
OBJCORE_MAGIC
);
AZ
(
bo
->
storage
);
bo
->
storage
=
bo
->
do_pass
?
stv_transient
:
STV_next
();
bo
->
storage
=
bo
->
uncacheable
?
stv_transient
:
STV_next
();
if
(
bo
->
retries
>
0
)
http_Unset
(
bo
->
bereq
,
"
\012
X-Varnish:"
);
...
...
@@ -406,7 +406,6 @@ vbf_stp_startfetch(struct worker *wrk, struct busyobj *bo)
VCL_backend_fetch_method
(
bo
->
vcl
,
wrk
,
NULL
,
bo
,
NULL
);
bo
->
uncacheable
=
bo
->
do_pass
;
if
(
wrk
->
handling
==
VCL_RET_ABANDON
||
wrk
->
handling
==
VCL_RET_FAIL
)
return
(
F_STP_FAIL
);
...
...
@@ -538,7 +537,7 @@ vbf_stp_startfetch(struct worker *wrk, struct busyobj *bo)
bo
->
uncacheable
=
1
;
wrk
->
handling
=
VCL_RET_DELIVER
;
}
if
(
bo
->
do_pass
||
bo
->
uncacheable
)
if
(
bo
->
uncacheable
)
oc
->
flags
|=
OC_F_HFM
;
assert
(
wrk
->
handling
==
VCL_RET_DELIVER
);
...
...
@@ -1114,7 +1113,7 @@ VBF_Fetch(struct worker *wrk, struct req *req, struct objcore *oc,
switch
(
mode
)
{
case
VBF_PASS
:
how
=
"pass"
;
bo
->
do_pass
=
1
;
bo
->
uncacheable
=
1
;
break
;
case
VBF_NORMAL
:
how
=
"fetch"
;
...
...
bin/varnishd/cache/cache_req_fsm.c
View file @
9aa7fae2
...
...
@@ -201,6 +201,8 @@ Resp_Setup_Synth(struct req *req)
http_SetHeader
(
h
,
"Connection: close"
);
}
#include <stdio.h>
static
enum
req_fsm_nxt
v_matchproto_
(
req_state_f
)
cnt_deliver
(
struct
worker
*
wrk
,
struct
req
*
req
)
{
...
...
bin/varnishd/cache/cache_vrt_var.c
View file @
9aa7fae2
...
...
@@ -262,7 +262,7 @@ VRT_r_bereq_uncacheable(VRT_CTX)
{
CHECK_OBJ_NOTNULL
(
ctx
,
VRT_CTX_MAGIC
);
CHECK_OBJ_NOTNULL
(
ctx
->
bo
,
BUSYOBJ_MAGIC
);
return
(
ctx
->
bo
->
do_pass
);
return
(
ctx
->
bo
->
uncacheable
);
}
VCL_VOID
...
...
include/tbl/bo_flags.h
View file @
9aa7fae2
...
...
@@ -39,7 +39,6 @@ BO_FLAG(do_esi, 0, 1, 1, 1, "")
BO_FLAG
(
do_gzip
,
0
,
1
,
1
,
1
,
""
)
BO_FLAG
(
do_gunzip
,
0
,
1
,
1
,
1
,
""
)
BO_FLAG
(
do_stream
,
0
,
1
,
1
,
0
,
""
)
BO_FLAG
(
do_pass
,
0
,
0
,
0
,
0
,
""
)
BO_FLAG
(
uncacheable
,
0
,
0
,
0
,
0
,
""
)
BO_FLAG
(
was_304
,
0
,
1
,
0
,
0
,
""
)
BO_FLAG
(
is_bgfetch
,
1
,
0
,
0
,
0
,
""
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment