diff options
author | ijon <ijon@yandex-team.com> | 2023-02-16 10:48:55 +0300 |
---|---|---|
committer | ijon <ijon@yandex-team.com> | 2023-02-16 10:48:55 +0300 |
commit | 2833f666f68066051c16ce5769ed730127293cdc (patch) | |
tree | eb2ae33a451a47763a9033b56eae91ca2055b694 /util/stream/printf.h | |
parent | 0c383af328f81a22f2d28f7ac626e56506c2bb6c (diff) | |
download | ydb-2833f666f68066051c16ce5769ed730127293cdc.tar.gz |
tx_proxy, tests: remove excess waiting in CheckTableBecome*()
Use TTestActorRuntimeBase::DispatchTimeout manipulation to achieve
proper (small) wait times.
The reason to this is that timeout value given to CheckTableBecome*()
propagates first to Tests:TClient::WaitForTablet*(), then propagates
to NActors::TTestActorsRuntimebase::GrabEdgeEvent().
Timeout parameter to GrabEdgeEvent*() is a timeout in a simulated time.
Timeout mechanics does not work if time does not get updated during a simulation.
And entire time simulation mechanics does not work if TTestActorRuntimeBase
is used with UseRealThreads setting set to true (which is the default).
And when timeout in a simulated time does not work, the only timeout
GrabEdgeEvent*() really obeys is DispatchTimeout which defaults to 60
seconds (or 120 seconds if code runs under some sanitizer).
Tests in ydb/core/tx/tx_proxy runs with UseRealThreads set to true,
so timeouts in CheckTableBecome*() methods do nothing, and whenever
tests wait for something that should never happen (and specify small
reasonable timeout value for that) they wait for 60 (or 120) seconds instead.
This change cuts run time of the affected tests from 7 minutes to 2.
Diffstat (limited to 'util/stream/printf.h')
0 files changed, 0 insertions, 0 deletions