rivercli: restore ability to set custom DriverProcurer#945
Merged
Conversation
79d204c to
e4c1df6
Compare
brandur
approved these changes
Jun 4, 2025
brandur
approved these changes
Jun 4, 2025
bgentry
commented
Jun 4, 2025
cmd/river/rivercli/command.go
Outdated
Comment on lines
80
to
81
| driverProcurer := bundle.DriverProcurer | ||
| if driverProcurer == nil && databaseURL != nil { |
Contributor
Author
There was a problem hiding this comment.
Ugh this doesn't quite cut it unfortunately. We'd have to initialize a DB pool separately in Pro prior to initializing its procurer (different than how this worked previously where it just passed in an existing pgx pool).
Contributor
Author
There was a problem hiding this comment.
Added an InitPgxV5() optional interface to allow injecting the pgxpool into a driver that can handle it. Tested the integration and this seems to work end-to-end.
Add an optional interface for a pgxv5 pool initializer so others don't need to somehow duplicate URL flag parsing and pool creation logic.
e4c1df6 to
5e96db9
Compare
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#870 broke a Pro CLI integration point for making Pro migrations available via a custom
DriverProcurer. This restores that ability to set a custom procurer.