Skip to content
This repository was archived by the owner on Dec 16, 2022. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
ebd0271
Support username/password GRPC auth
ys8 Nov 30, 2018
9c36fdc
The project already depends on Guava 26.0-jre, which reuqires Java 8.…
ys8 Nov 29, 2018
6838195
Test failure case
ys8 Nov 30, 2018
9d73c34
Make sure tabletserver is shutdown before cleaning up DB
Dec 2, 2018
18e1aa1
Stop server and also close te/messager/watcher
Dec 2, 2018
40ef7fe
This actually stops everything we need
Dec 2, 2018
b654418
Refactor place where clanup is done so it's clearer
Dec 2, 2018
06084a7
docker: update pmm-client from 1.15.0 to 1.17.0
derekperkins Dec 3, 2018
87a56ac
helm: update etcd version from 3.2.13 to 3.3.10
derekperkins Dec 3, 2018
30a1ebc
Merge pull request #4406 from tinyspeck/grpc-static-auth
demmer Dec 3, 2018
5084a4c
Updating configurations and dependency versions
Nov 24, 2018
4db4a28
Update all the protocol buffers with the new compiler
Nov 26, 2018
e8ba819
fix cert generation
deepthi Nov 27, 2018
875a305
Changes to TLS generation to create working encryption tests
Dec 2, 2018
8ca4a89
Fixing syntax and check errors from go 1.11
Dec 3, 2018
06c0f1b
Changing class signature of GRPC class for java package
Dec 3, 2018
63d2180
Merge pull request #4410 from planetscale/dk-update-versions-mariadb-…
sougou Dec 3, 2018
a52ace5
This log entry is too verbose and it will spam server logs
Dec 3, 2018
13bd1fe
helm: make pmm-client more resilient
derekperkins Dec 4, 2018
db10381
helm: add sample keyspace to values.yaml
derekperkins Dec 4, 2018
0248b31
helm: remove all resource limits and most requests
derekperkins Dec 4, 2018
52c5f0f
helm: change ImagePullPolicy to IfNotPresent
derekperkins Dec 4, 2018
749f5c2
helm: update suggested image tags and flavors
derekperkins Dec 4, 2018
0135684
helm: disable HPA by default
derekperkins Dec 4, 2018
c00a963
helm: values.yaml formatting cleanup
derekperkins Dec 4, 2018
1d74625
helm: bump chart to 1.0
derekperkins Dec 4, 2018
5b6b831
helm: fix default mysql/percona image tags
derekperkins Dec 4, 2018
0299d8e
Allow to set custom LoadBalancer.Factory and NameResolver.Factory
ys8 Dec 3, 2018
89ae7ef
Merge pull request #4416 from derekperkins/pmm
sougou Dec 4, 2018
a43fa63
Merge pull request #4414 from tinyspeck/java-grpc-factory
demmer Dec 4, 2018
5bec5a5
Merge pull request #4415 from tinyspeck/remove-verbose-log-entry
sougou Dec 5, 2018
130790f
Adds support for update by destination
Dec 5, 2018
e8c8a78
Merge pull request #4421 from tinyspeck/adds-update-by-dest
demmer Dec 5, 2018
3f5a312
Merge pull request #4413 from tinyspeck/fix-for-vtexplain
demmer Dec 5, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ function install_grpc() {
grpcio_ver=$version
$PIP install --upgrade grpcio=="$grpcio_ver" grpcio-tools=="$grpcio_ver"
}
install_dep "gRPC" "1.10.0" "$VTROOT/dist/grpc" install_grpc
install_dep "gRPC" "1.16.0" "$VTROOT/dist/grpc" install_grpc


# Install protoc.
Expand All @@ -153,7 +153,7 @@ function install_protoc() {
unzip "protoc-$version-$platform-x86_64.zip"
ln -snf "$dist/bin/protoc" "$VTROOT/bin/protoc"
}
protoc_ver=3.5.1
protoc_ver=3.6.1
install_dep "protoc" "$protoc_ver" "$VTROOT/dist/vt-protoc-$protoc_ver" install_protoc


Expand All @@ -169,11 +169,11 @@ function install_zookeeper() {
cp "$zk/contrib/fatjar/$zk-fatjar.jar" lib
# TODO(sougou): when version changes, see if we can drop the 'zip -d' hack to get the fatjars working.
# If yes, also delete "zip" from the Dockerfile files and the manual build instructions again.
# 3.4.10 workaround: Delete META-INF files which should not be in there.
# 3.4.13 workaround: Delete META-INF files which should not be in there.
zip -d "lib/$zk-fatjar.jar" 'META-INF/*.SF' 'META-INF/*.RSA' 'META-INF/*SF'
rm -rf "$zk" "$zk.tar.gz"
}
zk_ver=3.4.10
zk_ver=3.4.13
install_dep "Zookeeper" "$zk_ver" "$VTROOT/dist/vt-zookeeper-$zk_ver" install_zookeeper


Expand All @@ -190,7 +190,7 @@ function install_etcd() {
rm "$tar_file"
ln -snf "$dist/etcd-${version}-linux-amd64/etcd" "$VTROOT/bin/etcd"
}
install_dep "etcd" "v3.1.0-rc.1" "$VTROOT/dist/etcd" install_etcd
install_dep "etcd" "v3.3.10" "$VTROOT/dist/etcd" install_etcd


# Download and install consul, link consul binary into our root.
Expand All @@ -203,7 +203,7 @@ function install_consul() {
unzip "consul_${version}_linux_amd64.zip"
ln -snf "$dist/consul" "$VTROOT/bin/consul"
}
install_dep "Consul" "1.0.6" "$VTROOT/dist/consul" install_consul
install_dep "Consul" "1.4.0" "$VTROOT/dist/consul" install_consul


# Install py-mock.
Expand Down Expand Up @@ -251,7 +251,7 @@ function install_chromedriver() {
unzip -o -q chromedriver_linux64.zip -d "$dist"
rm chromedriver_linux64.zip
}
install_dep "chromedriver" "2.40" "$VTROOT/dist/chromedriver" install_chromedriver
install_dep "chromedriver" "2.44" "$VTROOT/dist/chromedriver" install_chromedriver


#
Expand Down
2 changes: 0 additions & 2 deletions config/mycnf/default-fast.cnf
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ innodb_log_file_size = 1M
innodb_log_files_in_group = 2
innodb_log_group_home_dir = {{.InnodbLogGroupHomeDir}}
innodb_max_dirty_pages_pct = 75
innodb_support_xa = 0
innodb_thread_concurrency = 2
key_buffer_size = 2M
log-error = {{.ErrorLogPath}}
Expand All @@ -37,7 +36,6 @@ port = {{.MysqlPort}}
read-only
read_buffer_size = 1M
read_rnd_buffer_size = 1M
secure_file_priv = NULL
server-id = {{.ServerID}}
skip-name-resolve
# we now need networking for replication. this is a tombstone to simpler times.
Expand Down
9 changes: 4 additions & 5 deletions config/mycnf/default.cnf
Original file line number Diff line number Diff line change
Expand Up @@ -26,17 +26,16 @@ innodb_thread_concurrency = 20
key_buffer_size = 32M
log-error = {{.ErrorLogPath}}
long_query_time = 2
max_allowed_packet = 16M
max_connections = 100
max_allowed_packet = 64M
max_connections = 500
net_write_timeout = 60
pid-file = {{.PidFile}}
port = {{.MysqlPort}}
# all db instances should start in read-only mode - once the db is started and
# fully functional, we'll push it into read-write mode
read-only
read_buffer_size = 1M
read_rnd_buffer_size = 1M
secure_file_priv = NULL
read_buffer_size = 8M
read_rnd_buffer_size = 8M
server-id = {{.ServerID}}
skip-name-resolve
# all db instances should skip the slave startup - that way we can do any
Expand Down
2 changes: 2 additions & 0 deletions config/mycnf/master_mysql56.cnf
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ gtid_mode = ON
log_bin
log_slave_updates
enforce_gtid_consistency
secure_file_priv = NULL
innodb_support_xa = 0

# Crash-safe replication settings.
master_info_repository = TABLE
Expand Down
5 changes: 5 additions & 0 deletions config/mycnf/production.cnf
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Values for a production vitess deployment
innodb_buffer_pool_size = 1024M
innodb_log_file_size = 512M
innodb_log_buffer_size = 64M
max_connections = 1000
15 changes: 15 additions & 0 deletions data/test/vtgate/dml_cases.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1306,6 +1306,21 @@
}
}

# update with target destination
"update `user[-]`.user_extra set val = 1"
{
"Original": "update `user[-]`.user_extra set val = 1",
"Instructions": {
"Opcode": "UpdateByDestination",
"Keyspace": {
"Name": "user",
"Sharded": true
},
"Query": "update user_extra set val = 1",
"Table": "user_extra"
}
}

# update with no primary vindex on where clause (scatter update) - multi shard autocommit
"update /*vt+ MULTI_SHARD_AUTOCOMMIT=1 */ user_extra set val = 1"
{
Expand Down
8 changes: 4 additions & 4 deletions data/test/vtgate/unsupported_cases.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,6 @@
"select * from `user[-]`.user_metadata"
"unsupported: SELECT with a target destination"

# Unsupported UPDATE statement with a target destination
"update `user[-]`.user_metadata set id=2"
"unsupported: UPDATE with a target destination"

# Unsupported INSERT statement with a target destination
"insert into `user[-]`.user_metadata (a, b) values (1,2)"
"unsupported: INSERT with a target destination"
Expand All @@ -51,6 +47,10 @@
"DELETE FROM `user[-]@replica`.user_metadata limit 1"
"unsupported: DELETE statement with a replica target"

# Unsupported UPDATE statement with a replica target destination
"update `user[-]@replica`.user_metadata set id=2"
"unsupported: UPDATE statement with a replica target"

# order by on a cross-shard subquery
"select id from (select user.id, user.col from user join user_extra) as t order by id"
"unsupported: cannot order by on a cross-shard subquery"
Expand Down
2 changes: 1 addition & 1 deletion doc/GettingStarted.md
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ In addition, Vitess requires the software and libraries listed below.
4. Select a lock service from the options listed below. It is technically
possible to use another lock server, but plugins currently exist only
for ZooKeeper, etcd and consul.
- ZooKeeper 3.4.10 is included by default.
- ZooKeeper 3.4.13 is included by default.
- [Install etcd v3.0+](https://github.com/coreos/etcd/releases).
If you use etcd, remember to include the `etcd` command
on your path.
Expand Down
2 changes: 1 addition & 1 deletion docker/bootstrap/Dockerfile.common
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.10
FROM golang:1.11

# Install Vitess build dependencies
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
Expand Down
2 changes: 1 addition & 1 deletion docker/bootstrap/Dockerfile.mysql56
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM vitess/bootstrap:common

# Install MySQL 5.6
RUN for i in $(seq 1 10); do apt-key adv --recv-keys --keyserver ha.pool.sks-keyservers.net 5072E1F5 && break; done && \
RUN for i in $(seq 1 10); do apt-key adv --no-tty --recv-keys --keyserver pool.sks-keyservers.net 5072E1F5 && break; done && \
add-apt-repository 'deb http://repo.mysql.com/apt/debian/ stretch mysql-5.6' && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y mysql-server libmysqlclient-dev && \
Expand Down
2 changes: 1 addition & 1 deletion docker/bootstrap/Dockerfile.mysql57
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM vitess/bootstrap:common

# Install MySQL 5.7
RUN for i in $(seq 1 10); do apt-key adv --recv-keys --keyserver ha.pool.sks-keyservers.net 5072E1F5 && break; done && \
RUN for i in $(seq 1 10); do apt-key adv --no-tty --recv-keys --keyserver ha.pool.sks-keyservers.net 5072E1F5 && break; done && \
add-apt-repository 'deb http://repo.mysql.com/apt/debian/ stretch mysql-5.7' && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y mysql-server libmysqlclient-dev && \
Expand Down
2 changes: 1 addition & 1 deletion docker/bootstrap/Dockerfile.percona
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM vitess/bootstrap:common

# Install Percona 5.6
RUN for i in $(seq 1 10); do apt-key adv --keyserver keys.gnupg.net --recv-keys 8507EFA5 && break; done && \
RUN for i in $(seq 1 10); do apt-key adv --no-tty --keyserver keys.gnupg.net --recv-keys 8507EFA5 && break; done && \
add-apt-repository 'deb http://repo.percona.com/apt stretch main' && \
{ \
echo debconf debconf/frontend select Noninteractive; \
Expand Down
2 changes: 1 addition & 1 deletion docker/bootstrap/Dockerfile.percona57
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM vitess/bootstrap:common

# Install Percona 5.7
RUN for i in $(seq 1 10); do apt-key adv --keyserver keys.gnupg.net --recv-keys 8507EFA5 && break; done && \
RUN for i in $(seq 1 10); do apt-key adv --no-tty --keyserver keys.gnupg.net --recv-keys 8507EFA5 && break; done && \
add-apt-repository 'deb http://repo.percona.com/apt stretch main' && \
{ \
echo debconf debconf/frontend select Noninteractive; \
Expand Down
11 changes: 5 additions & 6 deletions docker/k8s/pmm-client/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,11 @@ FROM debian:stretch-slim

RUN apt-get update && \
apt-get upgrade -qq && \
apt-get install -y procps && \
apt-get install wget -qq --no-install-recommends && \
wget https://www.percona.com/redir/downloads/pmm-client/1.15.0/binary/debian/stretch/x86_64/pmm-client_1.15.0-1.stretch_amd64.deb && \
dpkg -i pmm-client_1.15.0-1.stretch_amd64.deb && \
rm pmm-client_1.15.0-1.stretch_amd64.deb && \
apt-get purge wget -qq && \
apt-get install procps wget ca-certificates -qq --no-install-recommends && \
wget https://www.percona.com/redir/downloads/pmm-client/1.17.0/binary/debian/stretch/x86_64/pmm-client_1.17.0-1.stretch_amd64.deb && \
dpkg -i pmm-client_1.17.0-1.stretch_amd64.deb && \
rm pmm-client_1.17.0-1.stretch_amd64.deb && \
apt-get purge wget ca-certificates -qq && \
apt-get autoremove -qq && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*
Expand Down
4 changes: 2 additions & 2 deletions docker/lite/Dockerfile.alpine
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ FROM alpine:3.8 AS staging

RUN mkdir -p /vt/vtdataroot/ && mkdir -p /vt/bin && mkdir -p /vt/src/vitess.io/vitess/web/vtctld2

COPY --from=builder /vt/src/vitess.io/vitess/web/vtctld /vt/src/vitess.io/web/
COPY --from=builder /vt/src/vitess.io/vitess/web/vtctld2/app /vt/src/vitess.io/web/vtctld2/
COPY --from=builder /vt/src/vitess.io/vitess/web/vtctld /vt/src/vitess.io/web/vtctld
COPY --from=builder /vt/src/vitess.io/vitess/web/vtctld2/app /vt/src/vitess.io/web/vtctld2/app
COPY --from=builder /vt/src/vitess.io/vitess/config /vt/config
COPY --from=builder /vt/bin/mysqlctld /vt/bin/
COPY --from=builder /vt/bin/vtctld /vt/bin/
Expand Down
4 changes: 2 additions & 2 deletions docker/test/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -204,9 +204,9 @@ fi
# Clean up host dir mounted VTDATAROOT
if [[ -n "$hostdir" ]]; then
# Use Docker user to clean up first, to avoid permission errors.
docker run --name=rm_$testid -v $hostdir:/vt/vtdataroot $image bash -c 'rm -rf /vt/vtdataroot/*'
#docker run --name=rm_$testid -v $hostdir:/vt/vtdataroot $image bash -c 'rm -rf /vt/vtdataroot/*'
docker rm -f rm_$testid &>/dev/null
rm -rf $hostdir
#rm -rf $hostdir
fi

# If requested, create the cache image.
Expand Down
3 changes: 1 addition & 2 deletions go/cmd/vtexplain/vtexplain.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ func getFileParam(flag, flagFile, name string) (string, error) {
}

func main() {
defer vtexplain.Stop()
defer exit.RecoverAll()
defer logutil.Flush()

Expand Down Expand Up @@ -178,7 +179,5 @@ func parseAndRun() error {
fmt.Print(vtexplain.ExplainsAsJSON(plans))
}

vtexplain.Stop()

return nil
}
4 changes: 1 addition & 3 deletions go/mysql/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -672,13 +672,11 @@ func (l *Listener) parseClientHandshakePacket(c *Conn, firstTime bool, data []by

// Decode connection attributes send by the client
if clientFlags&CapabilityClientConnAttr != 0 {
var attrs map[string]string
var err error
attrs, pos, err = parseConnAttrs(data, pos)
_, pos, err = parseConnAttrs(data, pos)
if err != nil {
return "", "", nil, err
}
log.Infof("Connection Attributes: %-v", attrs)
}

return username, authMethod, authResponse, nil
Expand Down
38 changes: 19 additions & 19 deletions go/vt/proto/automation/automation.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading