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

Commit0810e1f

Browse files
committed
Add GUC on distributed execution paths
1 parent97c3440 commit0810e1f

File tree

4 files changed

+14
-7
lines changed

4 files changed

+14
-7
lines changed

‎contrib/pg_exchange/hooks.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ HOOK_Baserel_paths(PlannerInfo *root, RelOptInfo *rel, Index rti,
3939
if (prev_set_rel_pathlist_hook)
4040
(*prev_set_rel_pathlist_hook) (root,rel,rti,rte);
4141

42-
add_exchange_paths(root,rel,rti,rte);
42+
if (enable_distributed_execution)
43+
add_exchange_paths(root,rel,rti,rte);
4344
}
4445

4546
staticbool

‎contrib/pg_exchange/nodeDistPlanExec.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ static CustomScanMethodsdistplanexec_plan_methods;
4444
staticCustomExecMethodsdistplanexec_exec_methods;
4545

4646
chardestsName[10]="DMQ_DESTS";
47-
char*network_interface;
47+
boolenable_distributed_execution;
4848

4949

5050
staticNode*CreateDistPlanExecState(CustomScan*node);

‎contrib/pg_exchange/nodeDistPlanExec.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ typedef struct
2727
}lcontext;
2828

2929

30-
externchar*network_interface;
30+
externboolenable_distributed_execution;
3131
externchardestsName[10];
3232
#defineDISTEXECPATHNAME"DistExecPath"
3333

‎contrib/pg_exchange/pg_exchange.c

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,16 @@ shmem_size(void)
6969
void
7070
_PG_init(void)
7171
{
72-
DefineCustomStringVariable("network_interface",
73-
"Set network interface for EXCHANGE communications",
74-
NULL,&network_interface,"lo",
75-
PGC_SUSET,GUC_NOT_IN_SAMPLE,NULL,NULL,NULL);
72+
DefineCustomBoolVariable("enable_distributed_execution",
73+
"Use distributed execution.",
74+
NULL,
75+
&enable_distributed_execution,
76+
true,
77+
PGC_USERSET,
78+
GUC_NOT_IN_SAMPLE,
79+
NULL,
80+
NULL,
81+
NULL);
7682

7783
EXCHANGE_Init_methods();
7884
DUMMYSCAN_Init_methods();

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp