avoid duplicate parameter, increase timeout

This commit is contained in:
Dmitry Rodionov
2022-08-05 19:02:16 +03:00
committed by Dmitry Rodionov
parent 7cd68a0c27
commit cdfa9fe705
2 changed files with 4 additions and 2 deletions

View File

@@ -299,7 +299,9 @@ class PgProtocol:
# change it by calling "SET statement_timeout" after
# connecting.
options = result.get('options', '')
result['options'] = f'-cstatement_timeout=120s {options}'
if "statement_timeout" not in options:
options = f'-cstatement_timeout=120s {options}'
result['options'] = options
return result
# autocommit=True here by default because that's what we need most of the time

View File

@@ -155,7 +155,7 @@ def start_pgbench_intensive_initialization(env: PgCompare, scale: int, done_even
f'-s{scale}',
'-i',
'-Idtg',
env.pg.connstr(options='-cstatement_timeout=360s')
env.pg.connstr(options='-cstatement_timeout=600s')
])
done_event.set()