Re: Issue - consecutive early-hint defined with "if" condition

2022-07-06 Thread Christopher Faulet

Le 7/4/22 à 11:19, Christopher Faulet a écrit :

Le 6/30/22 à 11:47, Krzysztof Kozłowski a écrit :

Hi,

I’m struggling with consecutive early-hint statements defined with if condition.

Considering below configuration:

http-request early-hint Link ">; rel="preload"; as="style"" if { path -i -m
beg /test1 }
http-request early-hint Link ">; rel="preload"; as="style"" if { path -i -m
beg /test2 }

I’m not getting HTTP 103 response to 2nd statement.
Response I’m getting with above config:

example.com/test1  response: HTTP/2 103 + HTTP/2 200
example.com/test2  response: HTTP/2 200

However if I add some dummy statement in between those early-hints like this:

http-request early-hint Link ">; rel="preload"; as="style"" if { path -i -m
beg /test1 }
http-request set-header X-Test "test-request"
http-request early-hint Link ">; rel="preload"; as="style"" if { path -i -m
beg /test2 }

I’m receiving HTTP 103 response to both statements as expected.
Response I’m getting with above config:

example.com/test1  response: HTTP/2 103 + HTTP/2 200
example.com/test2  response: HTTP/2 103 + HTTP/2 200

It looks like an issue with parsing early-hint statements which are defined with
"if” statement.

It’s my first message sent to this mailing list - so please excuse me if I miss
any information required to properly identify the problem. If I’m missing
anything - please do let me know.
I would appreciate any help here.

I’m using HAProxy version 2.4.15-7782e23



Thanks ! Indeed, I can confirm the issue. I'll try to fix it soon.



Hi,

It should be fixed now in 2.7-DEV but not backported yet. The commit:

  http://git.haproxy.org/?p=haproxy.git;a=commit;h=4c3d3d2

Thanks !
--
Christopher Faulet



Re: Issue - consecutive early-hint defined with "if" condition

2022-07-04 Thread Christopher Faulet

Le 6/30/22 à 11:47, Krzysztof Kozłowski a écrit :

Hi,

I’m struggling with consecutive early-hint statements defined with if condition.

Considering below configuration:

http-request early-hint Link ">; rel="preload"; as="style"" if { path -i -m 
beg /test1 }
http-request early-hint Link ">; rel="preload"; as="style"" if { path -i -m 
beg /test2 }


I’m not getting HTTP 103 response to 2nd statement.
Response I’m getting with above config:

example.com/test1  response: HTTP/2 103 + HTTP/2 200
example.com/test2  response: HTTP/2 200

However if I add some dummy statement in between those early-hints like this:

http-request early-hint Link ">; rel="preload"; as="style"" if { path -i -m 
beg /test1 }

http-request set-header X-Test "test-request"
http-request early-hint Link ">; rel="preload"; as="style"" if { path -i -m 
beg /test2 }


I’m receiving HTTP 103 response to both statements as expected.
Response I’m getting with above config:

example.com/test1  response: HTTP/2 103 + HTTP/2 200
example.com/test2  response: HTTP/2 103 + HTTP/2 200

It looks like an issue with parsing early-hint statements which are defined with 
"if” statement.


It’s my first message sent to this mailing list - so please excuse me if I miss 
any information required to properly identify the problem. If I’m missing 
anything - please do let me know.

I would appreciate any help here.

I’m using HAProxy version 2.4.15-7782e23



Thanks ! Indeed, I can confirm the issue. I'll try to fix it soon.

--
Christopher Faulet



Issue - consecutive early-hint defined with "if" condition

2022-06-30 Thread Krzysztof Kozłowski
Hi,

I’m struggling with consecutive early-hint statements defined with if 
condition. 

Considering below configuration:

http-request early-hint Link "; rel="preload"; 
as="style"" if { path -i -m beg /test1 }
http-request early-hint Link "; rel="preload"; 
as="style"" if { path -i -m beg /test2 }

I’m not getting HTTP 103 response to 2nd statement.
Response I’m getting with above config:

example.com/test1 response: HTTP/2 103 + HTTP/2 200
example.com/test2 response: HTTP/2 200

However if I add some dummy statement in between those early-hints like this:

http-request early-hint Link "; rel="preload"; 
as="style"" if { path -i -m beg /test1 }
http-request set-header X-Test "test-request"
http-request early-hint Link "; rel="preload"; 
as="style"" if { path -i -m beg /test2 }

I’m receiving HTTP 103 response to both statements as expected.
Response I’m getting with above config:

example.com/test1 response: HTTP/2 103 + HTTP/2 200
example.com/test2 response: HTTP/2 103 + HTTP/2 200

It looks like an issue with parsing early-hint statements which are defined 
with "if” statement.

It’s my first message sent to this mailing list - so please excuse me if I miss 
any information required to properly identify the problem. If I’m missing 
anything - please do let me know.
I would appreciate any help here.

I’m using HAProxy version 2.4.15-7782e23

Thanks in advance

Krzysztof Kozłowski