1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-09 06:21:09 +03:00

Split xlog.c into xlog.c and xlogrecovery.c.

This moves the functions related to performing WAL recovery into the new
xlogrecovery.c source file, leaving xlog.c responsible for maintaining
the WAL buffers, coordinating the startup and switch from recovery to
normal operations, and other miscellaneous stuff that have always been in
xlog.c.

Reviewed-by: Andres Freund, Kyotaro Horiguchi, Robert Haas
Discussion: https://www.postgresql.org/message-id/a31f27b4-a31d-f976-6217-2b03be646ffa%40iki.fi
This commit is contained in:
Heikki Linnakangas
2022-02-16 09:30:38 +02:00
parent be1c00ab13
commit 70e81861fa
22 changed files with 4912 additions and 4379 deletions

View File

@@ -32,6 +32,7 @@ OBJS = \
xlogfuncs.o \
xloginsert.o \
xlogreader.o \
xlogrecovery.o \
xlogutils.o
include $(top_srcdir)/src/backend/common.mk

View File

@@ -29,6 +29,7 @@
#include "access/xact.h"
#include "access/xlog.h"
#include "access/xloginsert.h"
#include "access/xlogrecovery.h"
#include "access/xlogutils.h"
#include "catalog/index.h"
#include "catalog/namespace.h"

File diff suppressed because it is too large Load Diff

View File

@@ -19,8 +19,8 @@
#include <unistd.h>
#include "access/htup_details.h"
#include "access/xlog.h"
#include "access/xlog_internal.h"
#include "access/xlogrecovery.h"
#include "access/xlogutils.h"
#include "catalog/pg_type.h"
#include "funcapi.h"

File diff suppressed because it is too large Load Diff

View File

@@ -20,7 +20,7 @@
#include <unistd.h>
#include "access/timeline.h"
#include "access/xlog.h"
#include "access/xlogrecovery.h"
#include "access/xlog_internal.h"
#include "access/xlogutils.h"
#include "miscadmin.h"
@@ -46,8 +46,8 @@ bool ignore_invalid_pages = false;
* process you're running in, use RecoveryInProgress() but only after shared
* memory startup and lock initialization.
*
* This is updated from xlog.c, but lives here because it's mostly read by
* WAL redo functions.
* This is updated from xlog.c and xlogrecovery.c, but lives here because
* it's mostly read by WAL redo functions.
*/
bool InRecovery = false;