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

Ensure advisory lock CTE is MATERIALIZED on Postgres v12+ #179

Merged
merged 1 commit into from
Dec 17, 2020

Conversation

bensheldon
Copy link
Owner

@bensheldon bensheldon commented Dec 16, 2020

The advisory lock strategy uses a nested CTE that relies on the CTE being materialized to prevent the higher-level pg_try_advisory_lock condition from being pushed down.

Before Postgres 12, the materialized CTE was implicit; Postgres 12+ makes materialization explicit and disabled by default.

Connects to #177

@bensheldon bensheldon changed the title Add Postgres version matrix to tests Ensure advisory lock CTE is MATERIALIZED on Postgres v12+ Dec 16, 2020
@bensheldon bensheldon changed the title Ensure advisory lock CTE is MATERIALIZED on Postgres v12+ Ensure advisory lock CTE is MATERIALIZED on Postgres 12+ Dec 16, 2020
@bensheldon bensheldon changed the title Ensure advisory lock CTE is MATERIALIZED on Postgres 12+ Ensure advisory lock CTE is MATERIALIZED on Postgres v12+ Dec 16, 2020
@bensheldon bensheldon merged commit 878dc96 into main Dec 17, 2020
@bensheldon bensheldon deleted the postgres_matrix branch December 17, 2020 18:58
@bensheldon bensheldon added the bug Something isn't working label Dec 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant