PostgreSQL Source Code
git master
|
#include "postgres.h"
#include <limits.h>
#include "catalog/pg_tablespace.h"
#include "commands/tablespace.h"
#include "common/hashfn.h"
#include "miscadmin.h"
#include "storage/ipc.h"
#include "storage/fileset.h"
#include "utils/builtins.h"
Go to the source code of this file.
Functions | |
static void | FileSetPath (char *path, FileSet *fileset, Oid tablespace) |
static void | FilePath (char *path, FileSet *fileset, const char *name) |
static Oid | ChooseTablespace (const FileSet *fileset, const char *name) |
void | FileSetInit (FileSet *fileset) |
File | FileSetCreate (FileSet *fileset, const char *name) |
File | FileSetOpen (FileSet *fileset, const char *name, int mode) |
bool | FileSetDelete (FileSet *fileset, const char *name, bool error_on_failure) |
void | FileSetDeleteAll (FileSet *fileset) |
Definition at line 188 of file fileset.c.
References hash(), hash_any(), name, FileSet::ntablespaces, and FileSet::tablespaces.
Referenced by FilePath(), and FileSetCreate().
|
static |
Definition at line 199 of file fileset.c.
References ChooseTablespace(), FileSetPath(), MAXPGPATH, name, and snprintf.
Referenced by FileSetCreate(), FileSetDelete(), and FileSetOpen().
Definition at line 94 of file fileset.c.
References ChooseTablespace(), FilePath(), FileSetPath(), MAXPGPATH, name, PathNameCreateTemporaryDir(), PathNameCreateTemporaryFile(), tablespace, and TempTablespacePath().
Referenced by MakeNewFileSetSegment().
Definition at line 138 of file fileset.c.
References FilePath(), MAXPGPATH, name, and PathNameDeleteTemporaryFile().
Referenced by BufFileDeleteFileSet(), BufFileTruncateFileSet(), and MakeNewFileSetSegment().
void FileSetDeleteAll | ( | FileSet * | fileset | ) |
Definition at line 152 of file fileset.c.
References FileSetPath(), i, MAXPGPATH, FileSet::ntablespaces, PathNameDeleteTemporaryDir(), and FileSet::tablespaces.
Referenced by logicalrep_worker_onexit(), SharedFileSetDeleteAll(), and SharedFileSetOnDetach().
void FileSetInit | ( | FileSet * | fileset | ) |
Definition at line 54 of file fileset.c.
References FileSet::creator_pid, GetTempTablespaces(), i, InvalidOid, lengthof, MyDatabaseTableSpace, MyProcPid, FileSet::ntablespaces, FileSet::number, PrepareTempTablespaces(), and FileSet::tablespaces.
Referenced by SharedFileSetInit(), and stream_start_internal().
Definition at line 121 of file fileset.c.
References FilePath(), MAXPGPATH, mode, name, and PathNameOpenTemporaryFile().
Referenced by BufFileOpenFileSet().
Definition at line 174 of file fileset.c.
References FileSet::creator_pid, MAXPGPATH, FileSet::number, PG_TEMP_FILE_PREFIX, snprintf, tablespace, and TempTablespacePath().
Referenced by FilePath(), FileSetCreate(), and FileSetDeleteAll().