1
0
mirror of https://github.com/postgres/postgres.git synced 2025-10-25 13:17:41 +03:00

Add contrib/pg_logicalinspect.

This module provides SQL functions that allow to inspect logical
decoding components.

It currently allows to inspect the contents of serialized logical
snapshots of a running database cluster, which is useful for debugging
or educational purposes.

Author: Bertrand Drouvot
Reviewed-by: Amit Kapila, Shveta Malik, Peter Smith, Peter Eisentraut
Reviewed-by: David G. Johnston
Discussion: https://postgr.es/m/ZscuZ92uGh3wm4tW%40ip-10-97-1-34.eu-west-3.compute.internal
This commit is contained in:
Masahiko Sawada
2024-10-14 17:22:02 -07:00
parent e2fd615ecc
commit 7cdfeee320
18 changed files with 598 additions and 39 deletions

View File

@@ -15,6 +15,10 @@
#include "access/xlogdefs.h"
#include "utils/snapmgr.h"
/*
* Please keep get_snapbuild_state_desc() (located in the pg_logicalinspect
* module) updated if a change needs to be made to SnapBuildState.
*/
typedef enum
{
/*

View File

@@ -193,4 +193,7 @@ typedef struct SnapBuildOnDisk
/* variable amount of TransactionIds follows */
} SnapBuildOnDisk;
extern bool SnapBuildRestoreSnapshot(SnapBuildOnDisk *ondisk, const char *path,
MemoryContext context, bool missing_ok);
#endif /* SNAPBUILD_INTERNAL_H */