The flag controls the throttling of the copy.
By default, throttling is disabled.
Any throttling rate will be evenly distributed across all writer threads.
Next steps (outside of this PR) will be:
- use Throttler in vtworker and filtered replication
- implement MaxReplicationLag module
- implement a read-only webinterface which displays the actual and throttled rate
- make the webinterface read-write e.g. to override the fixed rate limit
- Removed previous Resolver interface and respective implementations.
- Removed respective stat vars and flags (--resolve_ttl).
- Added unit test for case where vtworker fails over to a different replica.
- Added unit test for case when healthcheck retries because currently no master is available.
- Extended FakePoolConnection to support these tests:
- can define callback (AfterFunc) when expected query was received
- infinite mode where the last request may be received over and over again
- discovery: Introduce DefaultTopoReadConcurrency to avoid duplication.
- discovery: Added EndPointStats.Alias() to avoid duplication.
- discovery: Added EndPointStats.String() to have pretty printed arrays.
Adapted end-to-end tests:
- binlog.py, merge_sharding.py, resharding.py: Enabled healthcheck for master tablets.
- worker.py: Updated stat vars check
- Moved out into own file.
- More code reuse between tests.
- Split split_clone_test.go into multiple tests to better sepearate between a test which tests the normal case and tests which test specific error situations.
Bug: b/28409793
MySQL sometimes sets stray flags that have to be ignored.
Specifically, for this query:
select max(uint) from t
MySQL sets the binary flag along with the unsigned flag.
The bug fix changes the behavior where vitess only looks at
the relevant flags and ignores all others.
All vindexes must accept sqltypes.Value because that's
how values are supplied for cross-shard joins.
I've also updated the example and the v3 e2e test.
We now wait synchronously for the first version, when we get them all we
build the initial vschema. We then process changes incrementally as we
did before.
Otherwise at startup, some keyspace vschemas may depend on others.
We will only log:
- an error when loading vschema once we have all keyspaces.
- any refresh error.
Removing this dependency makes it easier to reason about which components need synchronization and use the lock.
StatusWorker is now fully isolated and can be accessed only through its exported methods.
Other changes:
- Unexported remaining fields in StatusWorker
- Added State() to worker interface to deduplicate code in unit tests.
- created TabletStatusList which aggregates TableStatus objects and has its own lock now. By resing it, we reduce code duplication in SplitClone and VerticalSplitClone.
- Changed Status* functions to not use the previous global mutex. Instead, StatusWorker and TabletStatusList are called independently now.
We now use canonical errors. Note over the RPC channel we were always
sending the canonical errors already, and not really using the old style
errors anyway.