Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 83b4f19

Browse files
knizhnikkelvich
authored andcommitted
Add asserts to debug no transaction in progress
1 parent 6836421 commit 83b4f19

9 files changed

+420
-215
lines changed

arbiter.c

Lines changed: 143 additions & 100 deletions
Large diffs are not rendered by default.

bgwpool.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010

1111
#include "bgwpool.h"
1212

13+
bool MtmIsLogicalReceiver;
14+
1315
typedef struct
1416
{
1517
BgwPoolConstructor constructor;
@@ -24,6 +26,8 @@ static void BgwPoolMainLoop(Datum arg)
2426
int size;
2527
void* work;
2628

29+
MtmIsLogicalReceiver = true;
30+
2731
BackgroundWorkerUnblockSignals();
2832
BackgroundWorkerInitializeConnection(pool->dbname, pool->dbuser);
2933

bgwpool.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ typedef uint64 timestamp_t;
1616
extern timestamp_t MtmGetSystemTime(void); /* non-adjusted current system time */
1717
extern timestamp_t MtmGetCurrentTime(void); /* adjusted current system time */
1818

19+
extern bool MtmIsLogicalReceiver;
20+
1921
typedef struct
2022
{
2123
BgwPoolExecutor executor;

0 commit comments

Comments
 (0)