diff options
| author | Simon Riggs <simon@2ndQuadrant.com> | 2011-02-08 19:39:08 +0000 |
|---|---|---|
| committer | Simon Riggs <simon@2ndQuadrant.com> | 2011-02-08 19:39:08 +0000 |
| commit | c016ce728139be95bb0dc7c4e5640507334c2339 (patch) | |
| tree | 43b1708d3a4f637ddd5dcaa0474e8f9bedc9508e /src/include | |
| parent | 8c6e3adbf792c2bba448e88cbf2c8e03fb802e73 (diff) | |
| download | postgresql-c016ce728139be95bb0dc7c4e5640507334c2339.tar.gz | |
Named restore points in recovery. Users can record named points, then
new recovery.conf parameter recovery_target_name allows PITR to
specify named points as recovery targets.
Jaime Casanova, reviewed by Euler Taveira de Oliveira, plus minor edits
Diffstat (limited to 'src/include')
| -rw-r--r-- | src/include/access/xlog.h | 4 | ||||
| -rw-r--r-- | src/include/access/xlog_internal.h | 1 | ||||
| -rw-r--r-- | src/include/catalog/pg_control.h | 1 | ||||
| -rw-r--r-- | src/include/catalog/pg_proc.h | 1 |
4 files changed, 6 insertions, 1 deletions
diff --git a/src/include/access/xlog.h b/src/include/access/xlog.h index 122e96b5d1..e7adead9a2 100644 --- a/src/include/access/xlog.h +++ b/src/include/access/xlog.h @@ -184,7 +184,8 @@ typedef enum { RECOVERY_TARGET_UNSET, RECOVERY_TARGET_XID, - RECOVERY_TARGET_TIME + RECOVERY_TARGET_TIME, + RECOVERY_TARGET_NAME } RecoveryTargetType; extern XLogRecPtr XactLastRecEnd; @@ -302,6 +303,7 @@ extern void InitXLOGAccess(void); extern void CreateCheckPoint(int flags); extern bool CreateRestartPoint(int flags); extern void XLogPutNextOid(Oid nextOid); +extern XLogRecPtr XLogRestorePoint(const char *rpName); extern XLogRecPtr GetRedoRecPtr(void); extern XLogRecPtr GetInsertRecPtr(void); extern XLogRecPtr GetFlushRecPtr(void); diff --git a/src/include/access/xlog_internal.h b/src/include/access/xlog_internal.h index 6390113de3..eeccdce31d 100644 --- a/src/include/access/xlog_internal.h +++ b/src/include/access/xlog_internal.h @@ -267,6 +267,7 @@ extern XLogRecPtr RequestXLogSwitch(void); extern Datum pg_start_backup(PG_FUNCTION_ARGS); extern Datum pg_stop_backup(PG_FUNCTION_ARGS); extern Datum pg_switch_xlog(PG_FUNCTION_ARGS); +extern Datum pg_create_restore_point(PG_FUNCTION_ARGS); extern Datum pg_current_xlog_location(PG_FUNCTION_ARGS); extern Datum pg_current_xlog_insert_location(PG_FUNCTION_ARGS); extern Datum pg_last_xlog_receive_location(PG_FUNCTION_ARGS); diff --git a/src/include/catalog/pg_control.h b/src/include/catalog/pg_control.h index ddf139857d..fb458acf83 100644 --- a/src/include/catalog/pg_control.h +++ b/src/include/catalog/pg_control.h @@ -59,6 +59,7 @@ typedef struct CheckPoint #define XLOG_SWITCH 0x40 #define XLOG_BACKUP_END 0x50 #define XLOG_PARAMETER_CHANGE 0x60 +#define XLOG_RESTORE_POINT 0x70 /* diff --git a/src/include/catalog/pg_proc.h b/src/include/catalog/pg_proc.h index 734f43a1e4..30ff1b5bb9 100644 --- a/src/include/catalog/pg_proc.h +++ b/src/include/catalog/pg_proc.h @@ -3397,6 +3397,7 @@ DATA(insert OID = 2173 ( pg_stop_backup PGNSP PGUID 12 1 0 0 f f f t f v 0 0 2 DESCR("finish taking an online backup"); DATA(insert OID = 2848 ( pg_switch_xlog PGNSP PGUID 12 1 0 0 f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_switch_xlog _null_ _null_ _null_ )); DESCR("switch to new xlog file"); +DATA(insert OID = 3098 ( pg_create_restore_point PGNSP PGUID 12 1 0 0 f f f t f v 1 0 25 "25" _null_ _null_ _null_ _null_ pg_create_restore_point _null_ _null_ _null_ )); DATA(insert OID = 2849 ( pg_current_xlog_location PGNSP PGUID 12 1 0 0 f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_current_xlog_location _null_ _null_ _null_ )); DESCR("current xlog write location"); DATA(insert OID = 2852 ( pg_current_xlog_insert_location PGNSP PGUID 12 1 0 0 f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_current_xlog_insert_location _null_ _null_ _null_ )); |
