This PR implements support for pgx/v4 connection pool with their respective API usage, which differs from the standard database/sql. An example of output can be seen here!
The feature gets enabled when pointing out the driver field to pgx/v4, as in the example below:
version: "1"
packages:
- name: "db"
path: "internal/db"
queries: "schema.sql"
schema: "schema.sql"
engine: "postgresql"
driver: "pgx/v4"
If the field is not informed, it defaults to the current behavior.
This wasn't a huge change in terms of implementation, however there were a lot of tests files to be written, so I decided to create separate test files for both the old and new behaviors. That's the reason the number of modified files is quite big.
We've been using it in our projects and everything has been working nicely so far. We would love to get feedback on this and apply any changes if requested.