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

Commit6ba6ec0

Browse files
committed
Do pg_probackup paranoia testing
1 parent5a20987 commit6ba6ec0

File tree

3 files changed

+25
-1
lines changed

3 files changed

+25
-1
lines changed

‎.travis.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,5 @@ env:
2323
-PG_VERSION=12 PG_BRANCH=REL_12_STABLE TEST_CASE=tap
2424
-PG_VERSION=12 PG_BRANCH=REL_12_STABLE TEST_CASE=tap MODE=legacy
2525
-PG_VERSION=12 PG_BRANCH=REL_12_STABLE TEST_CASE=all
26-
-PG_VERSION=12 PG_BRANCH=REL_12_STABLE TEST_CASE=test_ptrack_multiple_segments TEST_REPEATS=5
26+
-PG_VERSION=12 PG_BRANCH=REL_12_STABLE TEST_CASE=all MODE=paranoia
27+
-PG_VERSION=12 PG_BRANCH=REL_12_STABLE TEST_CASE=test_ptrack_multiple_segments TEST_REPEATS=5 MODE=paranoia

‎patches/turn-off-hint-bits.diff

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
diff --git a/src/backend/access/heap/heapam_visibility.c b/src/backend/access/heap/heapam_visibility.c
2+
index 537e681b236..bd9f010f2ea 100644
3+
--- a/src/backend/access/heap/heapam_visibility.c
4+
+++ b/src/backend/access/heap/heapam_visibility.c
5+
@@ -113,6 +113,11 @@ static inline void
6+
SetHintBits(HeapTupleHeader tuple, Buffer buffer,
7+
uint16 infomask, TransactionId xid)
8+
{
9+
+/*
10+
+ * Turn off hint bits to test pg_probackup with PG_PROBACKUP_PARANOIA=ON,
11+
+ * i.e. doing per block checksums comparison.
12+
+ */
13+
+return;
14+
if (TransactionIdIsValid(xid))
15+
{
16+
/* NB: xid must be known committed here! */

‎run_tests.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,11 @@ cd postgres # Go to postgres dir
3333
echo"############### Applying ptrack patch"
3434
git apply -v -3 ../patches/$PG_BRANCH-ptrack-core.diff
3535

36+
if ["$MODE"="paranoia" ];then
37+
echo"############### Paranoia mode: applying turn-off-hint-bits.diff"
38+
git apply -v -3 ../patches/turn-off-hint-bits.diff
39+
fi
40+
3641
echo"############### Compiling Postgres"
3742
if ["$TEST_CASE"="tap" ]&& ["$MODE"="legacy" ];then
3843
./configure CFLAGS='-DEXEC_BACKEND' --disable-atomics --prefix=$PGHOME --enable-debug --enable-cassert --enable-depend --enable-tap-tests
@@ -97,6 +102,8 @@ else
97102
echo"############### Testing"
98103
if ["$MODE"="basic" ];then
99104
export PG_PROBACKUP_TEST_BASIC=ON
105+
elif ["$MODE"="paranoia" ];then
106+
export PG_PROBACKUP_PARANOIA=ON
100107
fi
101108

102109
if ["$TEST_CASE"="all" ];then

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp