Add database configuration to disable advisory locks.#33691
Add database configuration to disable advisory locks.#33691matthewd merged 1 commit intorails:masterfrom
Conversation
|
r? @kamipo (@rails-bot has picked a reviewer for you, use r? to override) |
|
r? @matthewd |
guides/source/configuring.md
Outdated
There was a problem hiding this comment.
This is a continuation of the preceding discussion of prepared_statements.
More generally, the above feels a bit heavy-weight for what should be relatively obscure configuration, to me. How about we combine the two: "By default Active Record uses database features like prepared statements and advisory locks. You might need to disable those features if you're using an external connection pooler like PgBouncer: [yaml]"?
There was a problem hiding this comment.
I know it's a departure from @prepared_statements, but I suspect this would be clearer as @advisory_locks_enabled, particularly for the callers below.
There was a problem hiding this comment.
Just returning @advisory_locks[_enabled] seems clear enough here
activerecord/CHANGELOG.md
Outdated
There was a problem hiding this comment.
Typo, and example goes above your name.
62b0da1 to
20bb397
Compare
|
@matthewd Thank you for reviewing, I've updated the PR as per your comments. |
|
🤘🏻❤️ |
| :logger, | ||
| :prepared_statements, | ||
| :lock, | ||
| :advisory_locks |
There was a problem hiding this comment.
Should this be :advisory_locks_enabled?
There was a problem hiding this comment.
I think it is matching prepared_statements. I'm fine with either one.
There was a problem hiding this comment.
The instance variable is named @advisory_locks_enabled.
There was a problem hiding this comment.
@georgeclaghorn Oops good catch. Thank you for fixing @kamipo 👍
|
Could this get a version bump (5.2.2 or 5.2.1.1)? Rails repository is very huge to fetch. |
|
This is only going to be present in Rails 6.0. And no, we only release when we think it is ready, we can't release after every merged PR. |
#31190