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

How to override default PostgreSQL server using this repository's deployment workflow #1

Open
2 tasks
zachsa opened this issue Nov 3, 2022 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@zachsa
Copy link
Collaborator

zachsa commented Nov 3, 2022

I found that PostgreSQL chooses the wrong query plan by default for the following statement:

EXPLAIN DELETE FROM public.values WHERE id = n;

From a post on the dba.stackexchange network, as well as some communication with @SephyLeigh, I have subsequently learned that there are quite a lot of opportunities in terms of performance via overriding default server configuration values. To begin with, setting the random_page_cost parameter to 3 (instead of the default 4) results in the server choosing a much faster query plan. So I can see that PostgreSQL server configuration needs to take into account the VM/hardware setup. Aside from adjusting the relative cost of random page access, it looks like there are some other easy wins here: https://postgis.net/workshops/zh_Hans/postgis-intro/tuning.html.

We need a mechanism to pass configuration overrides through the SAEON PostGIS Docker image (which is the default PostGIS docker image + a layer), through the default PostGIS Docker image, and to the PostgreSQL Docker image where the details on how to override configuration are documented.

@zachsa zachsa added the enhancement New feature or request label Nov 3, 2022
@zachsa zachsa changed the title PostgreSQL server configuration How to override default PostgreSQL server using this repositories deployment workflow Nov 3, 2022
@zachsa zachsa changed the title How to override default PostgreSQL server using this repositories deployment workflow How to override default PostgreSQL server using this repositories' deployment workflow Nov 3, 2022
@zachsa zachsa changed the title How to override default PostgreSQL server using this repositories' deployment workflow How to override default PostgreSQL server using this repository's deployment workflow Nov 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants