-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feature(spanner): Implement DML Support for Spanner #1197
base: master
Are you sure you want to change the base?
feature(spanner): Implement DML Support for Spanner #1197
Conversation
c60aa87
to
be12225
Compare
This PR supersedes the following PR #733, #910, #924 It is a robust implementation that greatly improves support for Spanner migrations. It also fixes a lot of open issues with the existing DDL parsing implementation. NOTE: Not sure why tests are failing, but it is not related to spanner tests. It looks like cockroachdb is having an issue. |
FYI: Now memefish has official release, so you don't need to use |
@dhui |
ed3767b
to
07e9f94
Compare
Closes #135
Closes #775
Closes #918
Closes #1194
Supersedes the following PRs #733, #910, #924
This PR implements DML support and uses the
memefish
lexer to parse the migrations, replacing the usage of thespansql
package. As a result, numerous otherspansql
related issues have been resolved.The following features have been implemented:
To maintain backward compatibility, the
x-clean-statements
option must be used to enable the above features.This PR also fixes a bug where a provided spanner client via
WithInstance()
is closed whenMigration.Close()
is called. According to Docs, the caller is responsible for closing the underlying database client. This fix brings the Spanner driver into compliance with the expected behavior.I am maintaining a fork with this fix for those who would like to use it.
Put the following replace directive you your projects
go.mod