test(cassandra): fix flaky test

This commit is contained in:
Thales Macedo Garitezi 2023-05-30 15:42:53 -03:00
parent 6be8ff378e
commit 8c565abc84
2 changed files with 5 additions and 2 deletions

View File

@ -541,7 +541,9 @@ t_write_failure(Config) ->
end),
fun(Trace0) ->
ct:pal("trace: ~p", [Trace0]),
Trace = ?of_kind(buffer_worker_flush_nack, Trace0),
Trace = ?of_kind(
[buffer_worker_flush_nack, buffer_worker_retry_inflight_failed], Trace0
),
[#{result := Result} | _] = Trace,
case Result of
{async_return, {error, {resource_error, _}}} ->

View File

@ -403,7 +403,8 @@ retry_inflight_sync(Ref, QueryOrBatch, Data0) ->
buffer_worker_retry_inflight_failed,
#{
ref => Ref,
query_or_batch => QueryOrBatch
query_or_batch => QueryOrBatch,
result => Result
}
),
{keep_state, Data1, {state_timeout, ResumeT, unblock}};