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

Commite1647b9

Browse files
knizhnikkelvich
authored andcommitted
Restore apply memory context after SPI call
1 parentf644229 commite1647b9

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

‎pglogical_apply.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -403,6 +403,7 @@ process_remote_message(StringInfo s)
403403
if (rc<0) {
404404
MTM_ELOG(ERROR,"Failed to execute utility statement %s",messageBody);
405405
}else {
406+
MemoryContextSwitchTo(MtmApplyContext);
406407
PushActiveSnapshot(GetTransactionSnapshot());
407408

408409
if (MtmVacuumStmt!=NULL) {

‎pglogical_receiver.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,8 @@ pglogical_receiver_main(Datum main_arg)
550550
if (stmt[0]=='Z'|| (stmt[0]=='M'&& (stmt[1]=='L'||stmt[1]=='A'||stmt[1]=='C'))) {
551551
MTM_LOG3("Process '%c' message from %d",stmt[1],nodeId);
552552
if (stmt[0]=='M'&&stmt[1]=='C') {/* concurrent DDL should be executed by parallel workers */
553-
MtmExecute(stmt,msg_len);
553+
//MtmExecute(stmt, msg_len);
554+
MtmExecutor(stmt,msg_len);
554555
}else {
555556
MtmExecutor(stmt,msg_len);/* all other messages can be processed by receiver itself */
556557
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp