REGTEST: make the IP+port logging test more reliable

On my machine, test log/b00000.vtc fails ~9/10 times. Apparently, the
connection is often marked as reset before the timeout strikes, so the
log shows "CD" flags instead of "cD". This fix does two things :
  1) shorten the client timeout to 1 millisecond instead of 5
  2) accept both "cD" and "CD" as valid termination states since the
     purpose is to validate the source address and port, and not the
     status itself.
This commit is contained in:
Willy Tarreau 2018-10-28 19:19:48 +01:00
parent e7a770ce80
commit f95838ca2d
1 changed files with 2 additions and 2 deletions

View File

@ -30,7 +30,7 @@ syslog Slg_1 -level notice {
recv
recv
recv info
expect ~ \"dip\":\"${h1_fe_1_addr}\",\"dport\":\"${h1_fe_1_port}.*\"ts\":\"cD\",\"
expect ~ \"dip\":\"${h1_fe_1_addr}\",\"dport\":\"${h1_fe_1_port}.*\"ts\":\"[cC]D\",\"
} -start
haproxy h1 -conf {
@ -40,7 +40,7 @@ haproxy h1 -conf {
defaults
log global
timeout connect 3000
timeout client 5
timeout client 1
timeout server 10000
frontend fe1