Movatterモバイル変換


[0]ホーム

URL:



Facebook
Postgres Pro
Facebook
Downloads
49.1. Initialization Functions
Prev UpChapter 49. Archive ModulesHome Next

49.1. Initialization Functions#

An archive library is loaded by dynamically loading a shared library with thearchive_library's name as the library base name. The normal library search path is used to locate the library. To provide the required archive module callbacks and to indicate that the library is actually an archive module, it needs to provide a function named_PG_archive_module_init. The result of the function must be a pointer to a struct of typeArchiveModuleCallbacks, which contains everything that the core code needs to know to make use of the archive module. The return value needs to be of server lifetime, which is typically achieved by defining it as astatic const variable in global scope.

typedef struct ArchiveModuleCallbacks{    ArchiveStartupCB startup_cb;    ArchiveCheckConfiguredCB check_configured_cb;    ArchiveFileCB archive_file_cb;    ArchiveShutdownCB shutdown_cb;} ArchiveModuleCallbacks;typedef const ArchiveModuleCallbacks *(*ArchiveModuleInit) (void);

Only thearchive_file_cb callback is required. The others are optional.


Prev Up Next
Chapter 49. Archive Modules Home 49.2. Archive Module Callbacks
pdfepub
Go to PostgreSQL 17
By continuing to browse this website, you agree to the use of cookies. Go toPrivacy Policy.

[8]ページ先頭

©2009-2025 Movatter.jp