-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add support for using jackc/pgx as a driver (#122)
This patch updates `pggen` to support using `jackc/pgx` as a database driver. `lib/pq` has entered maintenance mode, and `jackc/pgx` is the recommended replacement. I still cannot recommend using `jackc/pgx` as a driver at this time because it has [a bug][1] that prevents `pggen` from gracefully handling schema changes. Most of the changes involve tweaking our scanners to be able to consume both the data that `lib/pq` and `jackc/pgx` pass down. For the moment, the generated code still depends on `lib/pq` because we need to be able to use `lib/pq.Array` to scan arrays of values. Once `jackc/pgx` becomes the recommended driver, we will switch to using whatever the equivalent of `lib/pq.Array` is for `jackc/pgx` (or roll our own). We will not drop support for using `lib/pq` as a driver (likely not ever, but certainly not without a major version bump). This bumps our go versions, including the msgv. We need to bump the msgv because jackc/pgx does not support go 1.11. Closes #119 [1]: jackc/pgx#841
- Loading branch information
1 parent
6abe0df
commit 051c9f6
Showing
23 changed files
with
425 additions
and
112 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.