зеркало из https://github.com/github/vitess-gh.git
98 строки
2.8 KiB
Protocol Buffer
98 строки
2.8 KiB
Protocol Buffer
/*
|
|
Copyright 2019 The Vitess Authors.
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
*/
|
|
|
|
// This file contains the service definition for making management API
|
|
// calls to mysqlctld.
|
|
|
|
syntax = "proto3";
|
|
option go_package = "vitess.io/vitess/go/vt/proto/mysqlctl";
|
|
|
|
package mysqlctl;
|
|
|
|
import "topodata.proto";
|
|
import "vttime.proto";
|
|
|
|
message StartRequest{
|
|
repeated string mysqld_args = 1;
|
|
}
|
|
|
|
message StartResponse{}
|
|
|
|
message ShutdownRequest{
|
|
bool wait_for_mysqld = 1;
|
|
}
|
|
|
|
message ShutdownResponse{}
|
|
|
|
message RunMysqlUpgradeRequest{}
|
|
|
|
message RunMysqlUpgradeResponse{}
|
|
|
|
message ReinitConfigRequest{}
|
|
|
|
message ReinitConfigResponse{}
|
|
|
|
message RefreshConfigRequest{}
|
|
|
|
message RefreshConfigResponse{}
|
|
|
|
// MysqlCtl is the service definition
|
|
service MysqlCtl {
|
|
rpc Start(StartRequest) returns (StartResponse) {};
|
|
rpc Shutdown(ShutdownRequest) returns (ShutdownResponse) {};
|
|
rpc RunMysqlUpgrade(RunMysqlUpgradeRequest) returns (RunMysqlUpgradeResponse) {};
|
|
rpc ReinitConfig(ReinitConfigRequest) returns (ReinitConfigResponse) {};
|
|
rpc RefreshConfig(RefreshConfigRequest) returns (RefreshConfigResponse) {};
|
|
}
|
|
|
|
// BackupInfo is the read-only attributes of a mysqlctl/backupstorage.BackupHandle.
|
|
message BackupInfo {
|
|
string name = 1;
|
|
string directory = 2;
|
|
|
|
string keyspace = 3;
|
|
string shard = 4;
|
|
|
|
// The following fields will be extracted from the .Name field. If an error
|
|
// occurs during extraction/parsing, these fields may not be set, but
|
|
// VtctldServer.GetBackups will not fail.
|
|
|
|
topodata.TabletAlias tablet_alias = 5;
|
|
vttime.Time time = 6;
|
|
|
|
// The following fields are may or may not be currently set. Work is inflight
|
|
// to fully-support these fields in all backupengine/storage implementations.
|
|
// See https://github.com/vitessio/vitess/issues/8332.
|
|
|
|
// Engine is the name of the backupengine implementation used to create
|
|
// this backup.
|
|
string engine = 7;
|
|
Status status = 8;
|
|
|
|
// Status is an enum representing the possible status of a backup.
|
|
enum Status {
|
|
UNKNOWN = 0;
|
|
INCOMPLETE = 1;
|
|
COMPLETE = 2;
|
|
// A backup status of INVALID should be set if the backup is complete
|
|
// but unusable in some way (partial upload, corrupt file, etc).
|
|
INVALID = 3;
|
|
// A backup status of VALID should be set if the backup is both
|
|
// complete and usuable.
|
|
VALID = 4;
|
|
}
|
|
}
|