mirror of https://github.com/citusdata/citus.git
reset memory context at end of execution
parent
1b45cfb52e
commit
7714b60e5e
|
@ -58,7 +58,7 @@ CStoreTableAMGetOptions(void)
|
||||||
|
|
||||||
|
|
||||||
static MemoryContext
|
static MemoryContext
|
||||||
GetCStoreMemoryContext(void)
|
GetCStoreMemoryContext()
|
||||||
{
|
{
|
||||||
if (CStoreContext == NULL)
|
if (CStoreContext == NULL)
|
||||||
{
|
{
|
||||||
|
@ -69,6 +69,16 @@ GetCStoreMemoryContext(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
ResetCStoreMemoryContext()
|
||||||
|
{
|
||||||
|
if (CStoreContext != NULL)
|
||||||
|
{
|
||||||
|
MemoryContextReset(CStoreContext);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
cstore_init_write_state(Relation relation)
|
cstore_init_write_state(Relation relation)
|
||||||
{
|
{
|
||||||
|
@ -591,6 +601,7 @@ CStoreExecutorEnd(QueryDesc *queryDesc)
|
||||||
{
|
{
|
||||||
standard_ExecutorEnd(queryDesc);
|
standard_ExecutorEnd(queryDesc);
|
||||||
}
|
}
|
||||||
|
ResetCStoreMemoryContext();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue