vtctl: Revert that "master" is allowed as type for RunHealthCheck.

A tablet is never started with -tablet_type master and therefore the manual health check shouldn't support this as well. Nonetheless, any "replica" can become a "master".
This commit is contained in:
Michael Berlin 2015-08-18 13:12:45 -07:00
Родитель b231b69851
Коммит 66146f631f
2 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -911,7 +911,7 @@ func commandRunHealthCheck(ctx context.Context, wr *wrangler.Wrangler, subFlags
if err != nil {
return err
}
servedType, err := parseTabletType(subFlags.Arg(1), []pb.TabletType{pb.TabletType_MASTER, pb.TabletType_REPLICA, pb.TabletType_RDONLY})
servedType, err := parseTabletType(subFlags.Arg(1), []pb.TabletType{pb.TabletType_REPLICA, pb.TabletType_RDONLY})
if err != nil {
return err
}

Просмотреть файл

@ -407,7 +407,7 @@ primary key (name)
def _check_stream_health_equals_binlog_player_vars(self, tablet):
blp_stats = utils.get_vars(tablet.port)
# Enforce health check because it's not running by default as tablets are not started with it.
utils.run_vtctl(["RunHealthCheck", tablet.tablet_alias, 'master'])
utils.run_vtctl(["RunHealthCheck", tablet.tablet_alias, 'replica'])
stream_health, _ = utils.run_vtctl(['VtTabletStreamHealth',
'-count', '1',
tablet.tablet_alias],