mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-14 12:20:24 +00:00
Make cowboy_compress_h add vary: accept-encoding
This commit is contained in:
parent
1a9e62ae2a
commit
5ffb4f98e0
3 changed files with 79 additions and 4 deletions
|
@ -11,6 +11,9 @@ init(Req0, State=reply) ->
|
|||
cowboy_req:reply(200, #{}, lists:duplicate(100, $a), Req0);
|
||||
<<"large">> ->
|
||||
cowboy_req:reply(200, #{}, lists:duplicate(100000, $a), Req0);
|
||||
<<"vary">> ->
|
||||
Vary = cowboy_req:header(<<"x-test-vary">>, Req0),
|
||||
cowboy_req:reply(200, #{<<"vary">> => Vary}, lists:duplicate(100000, $a), Req0);
|
||||
<<"over-threshold">> ->
|
||||
cowboy_req:reply(200, #{}, lists:duplicate(200, $a), Req0);
|
||||
<<"content-encoding">> ->
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue