Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added note to the FAQ about SET search_path and pg_dump #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jamgregory
Copy link

We ran into the following issue today: https://gitlab.com/gitlab-org/gitlab-ce/issues/49089

I've added a note to the FAQ about issues around SET search_path so others are aware of it.

@jamgregory
Copy link
Author

Hi @petere 👋

Would it be possible to get this merged please?

@petere
Copy link
Member

petere commented Nov 2, 2018

I'm not sure under which circumstances you think this is applicable. By default, PgBouncer is configured to run DISCARD ALL after releasing a server, so there should be no stale session-level settings left behind.

@jamgregory
Copy link
Author

This doesn't appear to be the case unfortunately - when we were using PgBouncer with a Rails application. running an affected version of pg_dump caused PgBouncer to lose its search path settings, and the Rails application wouldn't work until PgBouncer was restarted. It may well be an issue with Rails specifically, but I thought it'd be useful to add as a caveat in case others experience the same issue.

@petere
Copy link
Member

petere commented Feb 6, 2019

If we are going to analyze this, you'll need to provide a reproducible test case.

@bduggan
Copy link

bduggan commented Feb 3, 2020

Hi folks, I can confirm that this behavior does exist; I've seen it with pg_dump version 10.6. Merging this PR would be great, unless there is a recommended configuration setting that would avoid it?

@markokr
Copy link
Contributor

markokr commented Feb 4, 2020

I am pretty sure you are talking about using pg_dump with pgbouncer running with pool_mode=transaction.

It is already documented that only subset of PostgreSQL features will work in such mode.

It would be mistake to document search_path as somehow being special case in respect to that.

@bduggan
Copy link

bduggan commented Feb 4, 2020

Hi @markokr -- thanks for the response! Yes, you are correct, this is in pool_mode=transaction.

I am not suggest documenting this as a special_case, but rather calling out the fact that what is normally a very benign operation -- using pg_dump -- can in fact be extremely disruptive.

Perhaps the wording can be adjusted to say that this only applies in pool_mode=transaction.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants