mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-07 00:27:30 +08:00
Previously, executor nodes running in parallel worker processes didn't have access to the dsm_segment object used for parallel execution. In order to support resource management based on DSM segment lifetime, they need that. So create a ParallelWorkerContext object to hold it and pass it to all InitializeWorker functions. Author: Thomas Munro Reviewed-By: Andres Freund Discussion: https://postgr.es/m/CAEepm=2W=cOkiZxcg6qiFQP-dHUe09aqTrEMM7yJDrHMhDv_RA@mail.gmail.com
35 lines
1.2 KiB
C
35 lines
1.2 KiB
C
/*-------------------------------------------------------------------------
|
|
*
|
|
* nodeForeignscan.h
|
|
*
|
|
*
|
|
*
|
|
* Portions Copyright (c) 1996-2017, PostgreSQL Global Development Group
|
|
* Portions Copyright (c) 1994, Regents of the University of California
|
|
*
|
|
* src/include/executor/nodeForeignscan.h
|
|
*
|
|
*-------------------------------------------------------------------------
|
|
*/
|
|
#ifndef NODEFOREIGNSCAN_H
|
|
#define NODEFOREIGNSCAN_H
|
|
|
|
#include "access/parallel.h"
|
|
#include "nodes/execnodes.h"
|
|
|
|
extern ForeignScanState *ExecInitForeignScan(ForeignScan *node, EState *estate, int eflags);
|
|
extern void ExecEndForeignScan(ForeignScanState *node);
|
|
extern void ExecReScanForeignScan(ForeignScanState *node);
|
|
|
|
extern void ExecForeignScanEstimate(ForeignScanState *node,
|
|
ParallelContext *pcxt);
|
|
extern void ExecForeignScanInitializeDSM(ForeignScanState *node,
|
|
ParallelContext *pcxt);
|
|
extern void ExecForeignScanReInitializeDSM(ForeignScanState *node,
|
|
ParallelContext *pcxt);
|
|
extern void ExecForeignScanInitializeWorker(ForeignScanState *node,
|
|
ParallelWorkerContext *pwcxt);
|
|
extern void ExecShutdownForeignScan(ForeignScanState *node);
|
|
|
|
#endif /* NODEFOREIGNSCAN_H */
|