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
255fe951
Commit
255fe951
authored
May 13, 2013
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change args to http_FilterReq() to a lower level.
parent
adab8d84
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
10 deletions
+16
-10
cache.h
bin/varnishd/cache/cache.h
+1
-1
cache_req_fsm.c
bin/varnishd/cache/cache_req_fsm.c
+15
-9
No files found.
bin/varnishd/cache/cache.h
View file @
255fe951
...
...
@@ -856,7 +856,7 @@ void HTTP_Init(void);
void
http_ClrHeader
(
struct
http
*
to
);
void
http_SetResp
(
struct
http
*
to
,
const
char
*
proto
,
uint16_t
status
,
const
char
*
response
);
void
http_FilterReq
(
const
struct
req
*
,
unsigned
how
);
void
http_FilterReq
(
struct
http
*
to
,
const
struct
http
*
fm
,
unsigned
how
);
void
http_FilterResp
(
const
struct
http
*
fm
,
struct
http
*
to
,
unsigned
how
);
void
http_PutProtocol
(
const
struct
http
*
to
,
const
char
*
protocol
);
void
http_PutStatus
(
struct
http
*
to
,
uint16_t
status
);
...
...
bin/varnishd/cache/cache_req_fsm.c
View file @
255fe951
...
...
@@ -772,27 +772,27 @@ cnt_lookup(struct worker *wrk, struct req *req)
switch
(
lr
)
{
case
HSH_EXP
:
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXXX EXP
\n
"
);
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXXX EXP
\n
"
);
AN
(
oc
);
AZ
(
boc
);
break
;
case
HSH_EXPBUSY
:
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXXX EXPBUSY
\n
"
);
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXXX EXPBUSY
\n
"
);
AN
(
oc
);
AN
(
boc
);
if
(
VDI_Healthy
(
req
->
director
,
req
->
digest
))
{
VSLb
(
req
->
vsl
,
SLT_Debug
,
"
deref oc
\n
"
);
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXX EXPBUSY
deref oc
\n
"
);
(
void
)
HSH_Deref
(
&
wrk
->
stats
,
oc
,
NULL
);
oc
=
boc
;
boc
=
NULL
;
}
else
{
VSLb
(
req
->
vsl
,
SLT_Debug
,
"
drop boc
\n
"
);
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXX EXPBUSY
drop boc
\n
"
);
(
void
)
HSH_Deref
(
&
wrk
->
stats
,
boc
,
NULL
);
boc
=
NULL
;
}
break
;
case
HSH_MISS
:
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXXX MISS
\n
"
);
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXXX MISS
\n
"
);
AZ
(
oc
);
AN
(
boc
);
oc
=
boc
;
...
...
@@ -800,7 +800,7 @@ VSLb(req->vsl, SLT_Debug, "XXXX MISS\n");
AN
(
oc
->
flags
&
OC_F_BUSY
);
break
;
case
HSH_HIT
:
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXXX HIT
\n
"
);
VSLb
(
req
->
vsl
,
SLT_Debug
,
"XXXX HIT
\n
"
);
AN
(
oc
);
AZ
(
boc
);
break
;
...
...
@@ -913,7 +913,9 @@ cnt_miss(struct worker *wrk, struct req *req)
AZ
(
req
->
obj
);
HTTP_Setup
(
bo
->
bereq
,
bo
->
ws
,
bo
->
vsl
,
HTTP_Bereq
);
http_FilterReq
(
req
,
HTTPH_R_FETCH
);
http_FilterReq
(
bo
->
bereq
,
req
->
http
,
HTTPH_R_FETCH
);
http_PrintfHeader
(
bo
->
bereq
,
"X-Varnish: %u"
,
req
->
vsl
->
wid
&
VSL_IDENTMASK
);
http_ForceGet
(
bo
->
bereq
);
if
(
cache_param
->
http_gzip_support
)
{
/*
...
...
@@ -988,7 +990,9 @@ cnt_pass(struct worker *wrk, struct req *req)
bo
=
req
->
busyobj
;
bo
->
refcount
=
2
;
HTTP_Setup
(
bo
->
bereq
,
bo
->
ws
,
bo
->
vsl
,
HTTP_Bereq
);
http_FilterReq
(
req
,
HTTPH_R_PASS
);
http_FilterReq
(
bo
->
bereq
,
req
->
http
,
HTTPH_R_PASS
);
http_PrintfHeader
(
bo
->
bereq
,
"X-Varnish: %u"
,
req
->
vsl
->
wid
&
VSL_IDENTMASK
);
VCL_backend_fetch_method
(
bo
->
vcl
,
wrk
,
NULL
,
bo
,
bo
->
bereq
->
ws
);
VCL_pass_method
(
bo
->
vcl
,
wrk
,
req
,
bo
,
bo
->
bereq
->
ws
);
...
...
@@ -1047,7 +1051,9 @@ cnt_pipe(struct worker *wrk, struct req *req)
req
->
busyobj
=
VBO_GetBusyObj
(
wrk
,
req
);
bo
=
req
->
busyobj
;
HTTP_Setup
(
bo
->
bereq
,
bo
->
ws
,
bo
->
vsl
,
HTTP_Bereq
);
http_FilterReq
(
req
,
0
);
http_FilterReq
(
bo
->
bereq
,
req
->
http
,
0
);
// XXX: 0 ?
http_PrintfHeader
(
bo
->
bereq
,
"X-Varnish: %u"
,
req
->
vsl
->
wid
&
VSL_IDENTMASK
);
VCL_pipe_method
(
req
->
vcl
,
wrk
,
req
,
NULL
,
req
->
http
->
ws
);
...
...
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