yugabyte/yugabyte-db

[YSQL] Add tserver gflag to set postgres process options

Open

#6 141 ouverte le 24 oct. 2020

Voir sur GitHub
 (6 commentaires) (0 réactions) (0 assignés)C (1 003 forks)batch import
area/ysqlgood first issuehelp wantedkind/enhancementkind/improve-uxpriority/medium

Métriques du dépôt

Stars
 (8 229 stars)
Métriques de merge PR
 (Merge moyen 17j 21h) (92 PRs mergées en 30 j)

Description

Jira Link: DB-2020 There doesn't seem to be a way to set postgres process options without editing the source code and compiling. Add a gflag to take those options, and make sure they override the defaults (whether that be making the options after the defaults or before, I don't know at the moment).

One use of this is using the -d N option to set different log levels (e.g. DEBUG3) for postgres. See src/postgres/src/backend/tcop/postgres.c function set_debug_options. Note that this is currently workaroundable by setting the underlying config options (e.g. debug_print_parse=true) in postgresql.conf.

src/yb/yql/pgwrapper/pg_wrapper.cc has PgWrapper::Start which sets arguments for the postgres process of a tserver. The tserver gflag can probably do its thing here.

Guide contributeur