[YSQL] Add tserver gflag to set postgres process options
#6.141 aberto em 24 de out. de 2020
Métricas do repositório
- Stars
- (8.229 stars)
- Métricas de merge de PR
- (Mesclagem média 17d 21h) (92 fundiu PRs em 30d)
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.