cockroach-go made a backwards-incompatible change to their transaction
function signatures, which was causing the cockroach instrumentation
to fail.
Updates the signature to match the cockraoch-go change.
Adds a readme to the cockroachdb database package, following the
postgres readme style.
Also adds the ability to force acquisition of the migration lock
via a connect URL parameter/WithInstance config, to allow for fixing
cases where an implementation error causes the schema lock to not
be released.
Lastly, tweaks the CLI readme to include information on building a
CLI for databases other than postgres.
Adds the ability to specify a series of commands to run as part
of the docker image execution, and allows for retrieving a mapping
of an exposed via the port bound within the container.
Adds support for CockroachDB. Cockroach uses the postges wire
protocol and has a large amount of common SQL functionality shared
with Postgres, so much of the postgres code was able to be copied
and modified.
Since the protocol is used in determining the driver, and the
Postgres protocol is also used by Cockroach, new connect string
prefixes were added: cockroach:// cockroachdb:// and
crdb-postgres://. These fake protocol strings are replaced in
the connect function with the correct `postgres://` protocol.
TODO: Tests needed (Cockroach has a docker image, so this shouldn't
be too hard)
Also includes some refactor around package naming, treats own repo as first-class and uses alternative package names for third party imports, Google spanner libraries in this case.
Support for Google Cloud Spanner, closes#172. Includes example migrations ported over from the PostgreSQL driver.
In all examples provided by Google I’ve come across, camel-case is used for table names, columns, etc. Hence the examples use this naming convention.