mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-05 16:17:34 +08:00
when user-defined functions used in a plan are modified. Also invalidate plans when schemas, operators, or operator classes are modified; but for these cases we just invalidate everything rather than tracking exact dependencies, since these types of objects seldom change in a production database. Tom Lane; loosely based on a patch by Martin Pihlak.
64 lines
1.7 KiB
C
64 lines
1.7 KiB
C
/*-------------------------------------------------------------------------
|
|
*
|
|
* inval.h
|
|
* POSTGRES cache invalidation dispatcher definitions.
|
|
*
|
|
*
|
|
* Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group
|
|
* Portions Copyright (c) 1994, Regents of the University of California
|
|
*
|
|
* $PostgreSQL: pgsql/src/include/utils/inval.h,v 1.44 2008/09/09 18:58:09 tgl Exp $
|
|
*
|
|
*-------------------------------------------------------------------------
|
|
*/
|
|
#ifndef INVAL_H
|
|
#define INVAL_H
|
|
|
|
#include "access/htup.h"
|
|
#include "utils/relcache.h"
|
|
|
|
|
|
typedef void (*SyscacheCallbackFunction) (Datum arg, int cacheid, ItemPointer tuplePtr);
|
|
typedef void (*RelcacheCallbackFunction) (Datum arg, Oid relid);
|
|
|
|
|
|
extern void AcceptInvalidationMessages(void);
|
|
|
|
extern void AtStart_Inval(void);
|
|
|
|
extern void AtSubStart_Inval(void);
|
|
|
|
extern void AtEOXact_Inval(bool isCommit);
|
|
|
|
extern void AtEOSubXact_Inval(bool isCommit);
|
|
|
|
extern void AtPrepare_Inval(void);
|
|
|
|
extern void PostPrepare_Inval(void);
|
|
|
|
extern void CommandEndInvalidationMessages(void);
|
|
|
|
extern void BeginNonTransactionalInvalidation(void);
|
|
|
|
extern void EndNonTransactionalInvalidation(void);
|
|
|
|
extern void CacheInvalidateHeapTuple(Relation relation, HeapTuple tuple);
|
|
|
|
extern void CacheInvalidateRelcache(Relation relation);
|
|
|
|
extern void CacheInvalidateRelcacheByTuple(HeapTuple classTuple);
|
|
|
|
extern void CacheInvalidateRelcacheByRelid(Oid relid);
|
|
|
|
extern void CacheRegisterSyscacheCallback(int cacheid,
|
|
SyscacheCallbackFunction func,
|
|
Datum arg);
|
|
|
|
extern void CacheRegisterRelcacheCallback(RelcacheCallbackFunction func,
|
|
Datum arg);
|
|
|
|
extern void inval_twophase_postcommit(TransactionId xid, uint16 info,
|
|
void *recdata, uint32 len);
|
|
|
|
#endif /* INVAL_H */
|