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
856e2fd0
Commit
856e2fd0
authored
Oct 17, 2023
by
Dag Haavi Finstad
Committed by
Dridi Boukelmoune
Oct 18, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Introduce RAPID_RESET as a sess_close reason
parent
9dda589c
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
24 additions
and
1 deletion
+24
-1
cache_http2_proto.c
bin/varnishd/http2/cache_http2_proto.c
+2
-1
r03996.vtc
bin/varnishtest/tests/r03996.vtc
+1
-0
h2_error.h
include/tbl/h2_error.h
+12
-0
sess_close.h
include/tbl/sess_close.h
+1
-0
VSC_main.vsc
lib/libvsc/VSC_main.vsc
+8
-0
No files found.
bin/varnishd/http2/cache_http2_proto.c
View file @
856e2fd0
...
...
@@ -46,6 +46,7 @@
#include "vtcp.h"
#include "vtim.h"
#define H2_CUSTOM_ERRORS
#define H2EC1(U,v,r,d) const struct h2_error_s H2CE_##U[1] = {{#U,d,v,0,1,r}};
#define H2EC2(U,v,r,d) const struct h2_error_s H2SE_##U[1] = {{#U,d,v,1,0,r}};
#define H2EC3(U,v,r,d) H2EC1(U,v,r,d) H2EC2(U,v,r,d)
...
...
@@ -345,7 +346,7 @@ h2_rapid_reset(struct worker *wrk, struct h2_sess *h2, struct h2_req *r2)
Lck_Lock
(
&
h2
->
sess
->
mtx
);
VSLb
(
h2
->
vsl
,
SLT_Error
,
"H2: Hit RST limit. Closing session."
);
Lck_Unlock
(
&
h2
->
sess
->
mtx
);
return
(
H2CE_
ENHANCE_YOUR_CALM
);
return
(
H2CE_
RAPID_RESET
);
}
h2
->
rst_budget
-=
1
.
0
;
return
(
0
);
...
...
bin/varnishtest/tests/r03996.vtc
View file @
856e2fd0
...
...
@@ -47,3 +47,4 @@ client c1 {
stream 0 -wait
} -run
varnish v1 -expect sc_rapid_reset == 1
include/tbl/h2_error.h
View file @
856e2fd0
...
...
@@ -147,5 +147,17 @@ H2_ERROR(
/* descr */
"Use HTTP/1.1 for the request"
)
#ifdef H2_CUSTOM_ERRORS
H2_ERROR
(
/* name */
RAPID_RESET
,
/* val */
11
,
/* ENHANCE_YOUR_CALM */
/* types */
1
,
/* reason */
SC_RAPID_RESET
,
/* descr */
"http/2 rapid reset detected"
)
# undef H2_CUSTOM_ERRORS
#endif
#undef H2_ERROR
/*lint -restore */
include/tbl/sess_close.h
View file @
856e2fd0
...
...
@@ -50,6 +50,7 @@ SESS_CLOSE(PIPE_OVERFLOW, pipe_overflow,1, "Session pipe overflow")
SESS_CLOSE
(
RANGE_SHORT
,
range_short
,
1
,
"Insufficient data for range"
)
SESS_CLOSE
(
REQ_HTTP20
,
req_http20
,
1
,
"HTTP2 not accepted"
)
SESS_CLOSE
(
VCL_FAILURE
,
vcl_failure
,
1
,
"VCL failure"
)
SESS_CLOSE
(
RAPID_RESET
,
rapid_reset
,
1
,
"HTTP2 rapid reset"
)
#undef SESS_CLOSE
/*lint -restore */
lib/libvsc/VSC_main.vsc
View file @
856e2fd0
...
...
@@ -634,6 +634,14 @@
Number of session closes with Error VCL_FAILURE (VCL failure)
.. varnish_vsc:: sc_rapid_reset
:level: diag
:oneliner: Session Err RAPID_RESET
Number of times we failed an http/2 session because it hit its
configured limits for the number of permitted rapid stream
resets.
.. varnish_vsc:: client_resp_500
:level: diag
:group: wrk
...
...
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