Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit65a4ec6

Browse files
author
Marina Polyakova
committed
Pgbench Fix TAP tests for retrying failed transactions 3
1 parent5229978 commit65a4ec6

File tree

1 file changed

+13
-12
lines changed

1 file changed

+13
-12
lines changed

‎src/bin/pgbench/t/004_retry_failed_transactions.pl

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -140,13 +140,13 @@ sub test_pgbench_serialization_failures
140140

141141
my$pattern =
142142
"client 0 sending UPDATE xy SET y = y\\+ (-?\\d+) WHERE x = 1;\n"
143-
."client 0 receiving\n"
143+
."(client 0 receiving\n)+"
144144
."client 0 got a serialization failure\\(attempt 1/2\\)\n"
145145
."client 0 sending END;\n"
146-
."client 0 receiving\n"
146+
."\\g2+"
147147
."client 0 repeats the failed transaction\\(attempt 2/2\\)\n"
148148
."client 0 sending BEGIN;\n"
149-
."client 0 receiving\n"
149+
."\\g2+"
150150
."client 0 executing\\\\set delta\n"
151151
."client 0 sending UPDATE xy SET y = y\\+\\g1 WHERE x = 1;";
152152

@@ -265,23 +265,24 @@ sub test_pgbench_deadlock_failures
265265
{
266266
my$pattern =
267267
"client 0 sending UPDATE xy SET y = y\\+ (-?\\d+) WHERE x = (\\d);\n"
268-
."client 0 receiving\n"
269-
."(|client 0 sending SELECT pg_sleep\\(20\\);\n"
270-
."client 0 receiving\n)"
268+
."(client 0 receiving\n)+"
269+
."(|client 0 sending SELECT pg_sleep\\(20\\);\n)"
270+
."\\g3*"
271271
."client 0 sending UPDATE xy SET y = y\\+ (-?\\d+) WHERE x = (\\d);\n"
272-
."client 0 receiving\n"
272+
."\\g3+"
273273
."client 0 got a deadlock failure\\(attempt 1/2\\)\n"
274274
."client 0 sending END;\n"
275-
."client 0 receiving\n"
275+
."\\g3+"
276276
."client 0 repeats the failed transaction\\(attempt 2/2\\)\n"
277277
."client 0 sending BEGIN;\n"
278-
."client 0 receiving\n"
278+
."\\g3+"
279279
."client 0 executing\\\\set delta1\n"
280280
."client 0 executing\\\\set delta2\n"
281281
."client 0 sending UPDATE xy SET y = y\\+\\g1 WHERE x =\\g2;\n"
282-
."client 0 receiving\n"
283-
."\\g3"
284-
."client 0 sending UPDATE xy SET y = y\\+\\g4 WHERE x =\\g5;\n";
282+
."\\g3+"
283+
."\\g4"
284+
."\\g3*"
285+
."client 0 sending UPDATE xy SET y = y\\+\\g5 WHERE x =\\g6;\n";
285286

286287
like($err1 .$err2,
287288
qr{$pattern},

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp