Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(cockroachdb): to use request driven options (#2883)
* feat: use recommended cluster settings for cockroachdb * fix: wrap errors * feat: add WithStatements option and expose recommended settings as a list of statements * Update modules/cockroachdb/options.go Co-authored-by: Steven Hartland <[email protected]> * Update modules/cockroachdb/cockroachdb.go Co-authored-by: Steven Hartland <[email protected]> * fix: return close error on defer * chore: improvement documentation and set default value for statements in defaultOptions * Update modules/cockroachdb/cockroachdb.go Co-authored-by: Manuel de la Peña <[email protected]> * chore: remove unnecessary nolint directive and rename ClusterDefaults to DefaultStatements * fix: only use recommended settings in root user tests * feat!(cockroachdb): simplify connection handling Simplify the connection handling in cockroachdb so that ConnectionString can be used without the user doing extra work to handle TLS if enabled. Deprecate TLSConfig which is no longer needed separately. BREAKING_CHANGE: This now returns a registered connection string so is no longer compatible with pgx.ParseConfig, use ConnectionConfig for this use case instead. * refactor(cockroachdb): to use request driven options Refactor cockroachdb module to to use request driven options, simplifying the flow. * fix: various fixes and remove certs Various fixes and remove the ability to configure certs using the default generated ones instead. * fix: add missing data files Add the missing data file and remove unused constants. * chore: add reference to ErrTLSNotEnabled * fix: lint failure for missing test helper * feat: tls strategy and strategy walk Extract TLS certificate wait strategy into a dedicated wait type so it can be reused. Implement walk method which can be used to identify wait strategies in a request chain. Use embed to simplify wait test loading of certs. * chore(cockroachdb): remove customizer Remove the now unused customizer. * fix: check setOptions error return * fix: lint style Fix lint style issue for blank line. * chore: various clean ups * docs(cockroachdb): clarified run defaults Clarified the impact of run defaults. --------- Co-authored-by: Martin Asquino <[email protected]> Co-authored-by: martskins <[email protected]> Co-authored-by: Manuel de la Peña <[email protected]>
- Loading branch information