This is the new connection management mode for vtgate.
We're now using the new mode in tests and examples by default,
rather than the old mode ("shardgateway").
This is more explicit. The Go "sql" package also talks about "drivers": https://golang.org/pkg/database/sql/
To get a sense how other drivers are named, here's a list: https://github.com/golang/go/wiki/SQLDrivers
We decided to have "vitess" in the name as well to make it clear in application code that this is the Vitess Go SQL driver.
also: Renamed main files from client*.go to driver*.go.
This gets rid of the opaque mysql-db-dir.tbz archive, replacing it with
a .sql file. The .sql file approach makes it clear what state the DB is
initialized with, and also makes it easy to customize.
Also allow -up.sh scripts to re-use existing data directories.
That way you can turn servers up and down without having to start over
from scratch every time.
This commit changes the following protocols:
- binlog_player_protocol
- vtctl_client_protocol
The only BSON protocol left is vtgate pending the implementation of the
gRPC vtgate client.
Note that we originally added this change in
https://github.com/youtube/vitess/pull/1230
However, we reverted it because the Kubernetes tutorial and images were
out of sync. Therefore, this commit technically is the revert of the
revert.
Revert "Revert "Change protocol defaults to grpc.""
This reverts commit 5e5f40a04e.
Since go/bson no longer encodes the non-standard uint64 type,
it's not safe to send uint64 over bsonrpc for a field that is
unmarshaled into interface{}, since it will be unmarshaled as int64.
The only case where this happens is bind vars. We could fix bsonrpc
by switching it to use bson-encoded proto3 structs, since those
use concrete field types for bind vars rather than interface{}.
However, bsonrpc is deprecated anyway so instead of fixing it,
we will just switch to grpc for all clients written in Go that
talk to queryservice.