Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion config/mycnf/default-fast.cnf
Original file line number Diff line number Diff line change
Expand Up @@ -61,5 +61,5 @@ tmpdir = {{.TmpDir}}
tmp_table_size = 32M
transaction-isolation = REPEATABLE-READ
# READ-COMMITTED would be better, but mysql 5.1 disables this with statement based replication
# READ-UNCOMMTTED might be better
# READ-UNCOMMITTED might be better
lower_case_table_names = 1
2 changes: 1 addition & 1 deletion config/mycnf/default.cnf
Original file line number Diff line number Diff line change
Expand Up @@ -61,5 +61,5 @@ tmpdir = {{.TmpDir}}
tmp_table_size = 32M
transaction-isolation = REPEATABLE-READ
# READ-COMMITTED would be better, but mysql 5.1 disables this with statement based replication
# READ-UNCOMMTTED might be better
# READ-UNCOMMITTED might be better
lower_case_table_names = 1
4 changes: 2 additions & 2 deletions doc/ReplicationGraph.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Replication Graph

The replication graph contains the mysql replication information for a shard. Currently, we only support one layer
of replication (a single master wiht multiple slaves), but the design doesn't preclude us from supporting
of replication (a single master with multiple slaves), but the design doesn't preclude us from supporting
hierarchical replication later on.

## Master
Expand All @@ -14,7 +14,7 @@ When creating a master (using 'vtctl InitTablet ... master'), we make sure Maste

The slaves are added to the ShardReplication object present on each local topology server. So for slaves, the
replication graph is colocated in the same cell as the tablets themselves. This makes disaster recovery much easier:
when loosing a data center, the replication graph for other data centers is not lost.
when losing a data center, the replication graph for other data centers is not lost.

When creating a slave (using 'vtctl InitTablet ... replica' for instance), we get the master record (if not specified) from the MasterAlias of the Shard. We then add an entry in the ReplicationLinks list of the ShardReplication object for the tablet’s cell (we create ShardReplication if it doesn’t exist yet).

Expand Down
2 changes: 1 addition & 1 deletion doc/Tools.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ This is useful for trouble-shooting, or to get a good high
level picture of all the servers and their current state.

### vtworker
vtworker is meant to host long-running processes. It supports a plugin infrastructure, and offers libraries to easily pick tablets to use. We have developped:
vtworker is meant to host long-running processes. It supports a plugin infrastructure, and offers libraries to easily pick tablets to use. We have developed:
- resharding differ jobs: meant to check data integrity during shard splits and joins.
- vertical split differ jobs: meant to check data integrity during vertical splits and joins.

Expand Down
2 changes: 1 addition & 1 deletion doc/ZookeeperData.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ type Shard struct {
}

// SourceShard represents a data source for filtered replication
// accross shards. When this is used in a destination shard, the master
// across shards. When this is used in a destination shard, the master
// of that shard will run filtered replication.
type SourceShard struct {
// Uid is the unique ID for this SourceShard object.
Expand Down
2 changes: 1 addition & 1 deletion go/cmd/vtworker/split_clone.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ const splitCloneHTML2 = `
<li><b>populateBlpCheckpoint</b>: creates (if necessary) and populates the blp_checkpoint table in the destination. Required for filtered replication to start.</li>
<li><b>dontStartBinlogPlayer</b>: (requires populateBlpCheckpoint) will setup, but not start binlog replication on the destination. The flag has to be manually cleared from the _vt.blp_checkpoint table.</li>
<li><b>skipAutoIncrement(TTT)</b>: we won't add the AUTO_INCREMENT back to that table.</li>
<li><b>skipSetSourceShards</b>: we won't set SourceShards on the destination shards, disabling filtered replication. Usefull for worker tests.</li>
<li><b>skipSetSourceShards</b>: we won't set SourceShards on the destination shards, disabling filtered replication. Useful for worker tests.</li>
</ul>
<p>The following flags are also supported, but their use is very strongly discouraged:</p>
<ul>
Expand Down
2 changes: 1 addition & 1 deletion go/cmd/vtworker/vertical_split_clone.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ const verticalSplitCloneHTML2 = `
<li><b>populateBlpCheckpoint</b>: creates (if necessary) and populates the blp_checkpoint table in the destination. Required for filtered replication to start.</li>
<li><b>dontStartBinlogPlayer</b>: (requires populateBlpCheckpoint) will setup, but not start binlog replication on the destination. The flag has to be manually cleared from the _vt.blp_checkpoint table.</li>
<li><b>skipAutoIncrement(TTT)</b>: we won't add the AUTO_INCREMENT back to that table.</li>
<li><b>skipSetSourceShards</b>: we won't set SourceShards on the destination shards, disabling filtered replication. Usefull for worker tests.</li>
<li><b>skipSetSourceShards</b>: we won't set SourceShards on the destination shards, disabling filtered replication. Useful for worker tests.</li>
</ul>
<p>The following flags are also supported, but their use is very strongly discouraged:</p>
<ul>
Expand Down
2 changes: 1 addition & 1 deletion go/event/event.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ var (
)

// BadListenerError is raised via panic() when AddListener is called with an
// invalid listener funcion.
// invalid listener function.
type BadListenerError string

func (why BadListenerError) Error() string {
Expand Down
2 changes: 1 addition & 1 deletion go/vt/dbconfigs/credentials.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ package dbconfigs

// This file contains logic for a plugable credentials system.
// The default implementation is file based.
// The flags are global, but only programs that need to acess the database
// The flags are global, but only programs that need to access the database
// link with this library, so we should be safe.

import (
Expand Down
2 changes: 1 addition & 1 deletion go/vt/mysqlctl/clone.go
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ func (mysqld *Mysqld) CreateSnapshot(logger logutil.Logger, dbName, sourceAddr s

// Stop sources of writes so we can get a consistent replication position.
// If the source is a slave use the master replication position
// unless we are allowing hierachical replicas.
// unless we are allowing hierarchical replicas.
masterAddr := ""
var replicationPosition proto.ReplicationPosition
if sourceIsMaster {
Expand Down
2 changes: 1 addition & 1 deletion go/vt/mysqlctl/mycnf_flag.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (

// This file handles using command line flags to create a Mycnf object.
// Since whoever links with this module doesn't necessarely need the flags,
// RegisterFlags needs to be called explicitely to set the flags up.
// RegisterFlags needs to be called explicitly to set the flags up.

var (
// the individual command line parameters
Expand Down
2 changes: 1 addition & 1 deletion go/vt/mysqlctl/split.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ func SanityCheckManifests(ssms []*SplitSnapshotManifest) error {
// need to replicate from. Can be ours if we are a master, or our master's.
func (mysqld *Mysqld) getReplicationPositionForClones(allowHierarchicalReplication bool) (replicationPosition proto.ReplicationPosition, masterAddr string, err error) {
// If the source is a slave use the master replication position,
// unless we are allowing hierachical replicas.
// unless we are allowing hierarchical replicas.
var status *proto.ReplicationStatus
status, err = mysqld.SlaveStatus()
if err == ErrNotSlave {
Expand Down
2 changes: 1 addition & 1 deletion go/vt/rpc/unused_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ func TestUnmarshalEmptyStructIntoStruct(t *testing.T) {
}

// It should always be possible to add fields to something that's already a
// struct. The struct name is irrelevent since it's never encoded.
// struct. The struct name is irrelevant since it's never encoded.
var out struct{ A, B string }
if err := bson.Unmarshal(buf, &out); err != nil {
t.Errorf("bson.Unmarshal: %v", err)
Expand Down
2 changes: 1 addition & 1 deletion go/vt/tableacl/tableacl_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ func TestAllowUnmatchedTable(t *testing.T) {
checkAccess(configData, "UNMATCHED_TABLE", ADMIN, t, true)
}

func TestAllUserReadAcess(t *testing.T) {
func TestAllUserReadAccess(t *testing.T) {
configData := []byte(`{"table[0-9]+":{"Reader":"` + ALL + `", "WRITER":"u3"}}`)
checkAccess(configData, "table1", READER, t, true)
}
Expand Down
2 changes: 1 addition & 1 deletion go/vt/tabletmanager/actionnode/actionnode.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

// Actions modify the state of a tablet, shard or keyspace.
//
// They are currenty managed through a series of queues stored in
// They are currently managed through a series of queues stored in
// topology server, or RPCs. Switching to RPCs only now.

package actionnode
Expand Down
6 changes: 3 additions & 3 deletions go/vt/tabletmanager/agent_rpc_actions.go
Original file line number Diff line number Diff line change
Expand Up @@ -654,7 +654,7 @@ func (agent *ActionAgent) RestartSlave(ctx context.Context, rsd *actionnode.Rest
return err
}
}
// Once this action completes, update authoritive tablet node first.
// Once this action completes, update authoritative tablet node first.
tablet.Parent = rsd.Parent
err = topo.UpdateTablet(ctx, agent.TopoServer, tablet)
if err != nil {
Expand Down Expand Up @@ -703,7 +703,7 @@ func (agent *ActionAgent) SlaveWasRestarted(ctx context.Context, swrd *actionnod
return err
}

// Once this action completes, update authoritive tablet node first.
// Once this action completes, update authoritative tablet node first.
tablet.Parent = swrd.Parent
if tablet.Type == topo.TYPE_MASTER {
tablet.Type = topo.TYPE_SPARE
Expand Down Expand Up @@ -1062,7 +1062,7 @@ func (agent *ActionAgent) MultiSnapshot(ctx context.Context, args *actionnode.Mu
sr := &actionnode.MultiSnapshotReply{ManifestPaths: filenames}
if tablet.Parent.Uid == topo.NO_TABLET {
// If this is a master, this will be the new parent.
// FIXME(msolomon) this doens't work in hierarchical replication.
// FIXME(msolomon) this doesn't work in hierarchical replication.
sr.ParentAlias = tablet.Alias
} else {
sr.ParentAlias = tablet.Parent
Expand Down
4 changes: 2 additions & 2 deletions go/vt/topo/keyspace.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import (
// KeyspaceServedFrom is a per-cell record to redirect traffic to another
// keyspace. Used for vertical splits.
type KeyspaceServedFrom struct {
// who is targetted
// who is targeted
Cells []string // nil means all cells

// where to redirect
Expand Down Expand Up @@ -47,7 +47,7 @@ type Keyspace struct {
// cover 1/Nth of the entire space or more.
// It is usually the number of shards in the system. If a keyspace
// is being resharded from M to P shards, it should be max(M, P).
// That way we can guarantee a query that is targetted to 1/N of the
// That way we can guarantee a query that is targeted to 1/N of the
// keyspace will land on just one shard.
SplitShardCount int32
}
Expand Down
2 changes: 1 addition & 1 deletion go/vt/topo/shard.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ func removeCells(cells, toRemove, fullList []string) ([]string, bool) {
}

// SourceShard represents a data source for filtered replication
// accross shards. When this is used in a destination shard, the master
// across shards. When this is used in a destination shard, the master
// of that shard will run filtered replication.
type SourceShard struct {
// Uid is the unique ID for this SourceShard object.
Expand Down
2 changes: 1 addition & 1 deletion go/vt/topo/srvshard.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const SHARD_ZERO = "0"
// SrvShard contains a roll-up of the shard in the local namespace.
// In zk, it is under /zk/<cell>/vt/ns/<keyspace>/<shard>
type SrvShard struct {
// Copied / infered from Shard
// Copied / inferred from Shard
Name string
KeyRange key.KeyRange
ServedTypes []TabletType
Expand Down
2 changes: 1 addition & 1 deletion go/vt/topo/tablet.go
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ func IsTrivialTypeChange(oldTabletType, newTabletType TabletType) bool {

// IsValidTypeChange returns if we should we allow this transition at
// all. Most transitions are allowed, but some don't make sense under
// any circumstances. If a transistion could be forced, don't disallow
// any circumstances. If a transition could be forced, don't disallow
// it here.
func IsValidTypeChange(oldTabletType, newTabletType TabletType) bool {
switch oldTabletType {
Expand Down
2 changes: 1 addition & 1 deletion go/vt/topotools/topology.go
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ func DbTopology(ts topo.Server) (*Topology, error) {
Partial: false,
}

tabletInfos, err := GetAllTabletsAccrossCells(ts)
tabletInfos, err := GetAllTabletsAcrossCells(ts)
switch err {
case nil:
// we're good, no error
Expand Down
4 changes: 2 additions & 2 deletions go/vt/topotools/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ func GetAllTablets(ts topo.Server, cell string) ([]*topo.TabletInfo, error) {
return tablets, nil
}

// GetAllTabletsAccrossCells returns all tablets from known cells.
// GetAllTabletsAcrossCells returns all tablets from known cells.
// If it returns topo.ErrPartialResult, then the list is valid, but partial.
func GetAllTabletsAccrossCells(ts topo.Server) ([]*topo.TabletInfo, error) {
func GetAllTabletsAcrossCells(ts topo.Server) ([]*topo.TabletInfo, error) {
cells, err := ts.GetKnownCells()
if err != nil {
return nil, err
Expand Down
2 changes: 1 addition & 1 deletion go/vt/vtgate/balancer.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ type addressStatus struct {
balancer *Balancer
}

// NewBalancer creates a Balancer. getAddreses is the function
// NewBalancer creates a Balancer. getAddresses is the function
// it will use to refresh the list of addresses if one of the
// nodes has been marked down. The list of addresses is shuffled.
// retryDelay specifies the minimum time a node will be marked down
Expand Down
2 changes: 1 addition & 1 deletion go/vt/vtgate/planbuilder/registrar.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ type Functional interface {
Unique
}

// A FuncionalGenerator vindex is a Functional vindex
// A FunctionalGenerator vindex is a Functional vindex
// that can generate new ids.
type FunctionalGenerator interface {
Functional
Expand Down
2 changes: 1 addition & 1 deletion go/vt/worker/diff_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ func NewRowReader(queryResultReader *QueryResultReader) *RowReader {
// Next will return:
// (row, nil) for the next row
// (nil, nil) for EOF
// (nil, error) if an error occured
// (nil, error) if an error occurred
func (rr *RowReader) Next() ([]sqltypes.Value, error) {
if rr.currentResult == nil || rr.currentIndex == len(rr.currentResult.Rows) {
var ok bool
Expand Down
2 changes: 1 addition & 1 deletion go/vt/worker/row_splitter.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
)

// RowSplitter is a helper class to split rows into multiple
// subsets targetted to different shards.
// subsets targeted to different shards.
type RowSplitter struct {
Type key.KeyspaceIdType
ValueIndex int
Expand Down
4 changes: 2 additions & 2 deletions go/vt/wrangler/cleaner.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
// action cleanup steps, and execute them at the end in reverse
// order, with various guarantees.
type Cleaner struct {
// folowing members protected by lock
// following members protected by lock
mu sync.Mutex
actions []cleanerActionReference
}
Expand Down Expand Up @@ -79,7 +79,7 @@ func (cleaner *Cleaner) CleanUp(wr *Wrangler) error {
rec.RecordError(err)
wr.Logger().Errorf("action %v failed on %v: %v", actionReference.name, actionReference.target, err)
} else {
wr.Logger().Infof("action %v successfull on %v", actionReference.name, actionReference.target)
wr.Logger().Infof("action %v successful on %v", actionReference.name, actionReference.target)
}
}
cleaner.mu.Unlock()
Expand Down
2 changes: 1 addition & 1 deletion go/vt/wrangler/testlib/fake_tablet.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

/*
Package testlib contains utility methods to include in unit tests to
deal with topology common tasks, liek fake tablets and action loops.
deal with topology common tasks, like fake tablets and action loops.
*/
package testlib

Expand Down
2 changes: 1 addition & 1 deletion go/zk/zkutil.go
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ type zMutex struct {
ephemeral bool
}

// CreateMutex initializes an unaquired mutex. A mutex is released only
// CreateMutex initializes an unacquired mutex. A mutex is released only
// by Unlock. You can clean up a mutex with delete, but you should be
// careful doing so.
func CreateMutex(zconn Conn, zkPath string) ZLocker {
Expand Down
2 changes: 1 addition & 1 deletion py/cbson/cbson.c
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ static int buf_iter_from_buffer(PyObject* buffer_obj, BufIter* buf_iter, Py_buff
/* ------------------------------------------------------------------------ */


/* decode_element is the function prototype for parsing differnt
/* decode_element is the function prototype for parsing different
* values in the bson stream */
typedef PyObject* (*decode_element)(BufIter* buf_iter);

Expand Down
2 changes: 1 addition & 1 deletion py/vtdb/field_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ class List(list):
NoneType = type(None)

# FIXME(msolomon) we could make a SqlLiteral ABC and just type check.
# That doens't seem dramatically better than __sql_literal__ but it might
# That doesn't seem dramatically better than __sql_literal__ but it might
# be move self-documenting.

def convert_bind_vars(bind_variables):
Expand Down
2 changes: 1 addition & 1 deletion py/vtdb/keyrange.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@


class KeyRange(codec.BSONCoding):
"""Defintion of KeyRange object.
"""Definition of KeyRange object.

Vitess uses range based sharding. KeyRange denotes the range
for the sharding key. This class also provides bson encoding
Expand Down