8000 Merge branch 'xtm' of gitlab.postgrespro.ru:pgpro-dev/postgrespro int… · postgrespro/postgres_cluster@a69772f · GitHub
[go: up one dir, main page]

Skip to content

Commit a69772f

Browse files
committed
Merge branch 'xtm' of gitlab.postgrespro.ru:pgpro-dev/postgrespro into xtm
2 parents ed850db + bdafca6 commit a69772f

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

contrib/pg_dtm/pg_dtm.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -792,7 +792,9 @@ Datum
792792
dtm_begin_transaction(PG_FUNCTION_ARGS)
793793
{
794794
Assert(!TransactionIdIsValid(DtmNextXid));
795-
795+
if (dtm == NULL) {
796+
elog(ERROR, "DTM is not properly initialized, please check that pg_dtm plugin was added to shared_preload_libraries list in postgresql.conf");
797+
}
796798
DtmNextXid = DtmGlobalStartTransaction(&DtmSnapshot, &dtm->minXid);
797799
Assert(TransactionIdIsValid(DtmNextXid));
798800
XTM_INFO("%d: Start global transaction %d, dtm->minXid=%d\n", getpid(), DtmNextXid, dtm->minXid);

contrib/pg_dtm/tests/transfers.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,9 @@ func main() {
218218
var transferWg sync.WaitGroup
219219
var inspectWg sync.WaitGroup
220220

221+
fmt.Printf("preparing the database...\n")
221222
prepare_db()
223+
fmt.Printf("the database prepared\n")
222224

223225
cCommits := make(chan int)
224226
cAborts := make(chan int)

0 commit comments

Comments
 (0)
0