Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

chore: rename database metadata to database schema metadata (#7420)

Danny Xu42e12043a630
diff --git a/backend/api/v1/database_service.go b/backend/api/v1/database_service.go
index 7bc726b64e..8e6e21961d 100644
--- a/backend/api/v1/database_service.go
+++ b/backend/api/v1/database_service.go
@@ -1560,7 +1560,7 @@ func convertToDatabase(database *store.DatabaseMessage) *v1pb.Database {
}
}
-func convertDatabaseMetadata(metadata *storepb.DatabaseMetadata) *v1pb.DatabaseMetadata {
+func convertDatabaseMetadata(metadata *storepb.DatabaseSchemaMetadata) *v1pb.DatabaseMetadata {
m := &v1pb.DatabaseMetadata{
Name: metadata.Name,
CharacterSet: metadata.CharacterSet,
diff --git a/backend/plugin/advisor/catalog/finder.go b/backend/plugin/advisor/catalog/finder.go
index 31e9618bb9..4497518d0d 100644
--- a/backend/plugin/advisor/catalog/finder.go
+++ b/backend/plugin/advisor/catalog/finder.go
@@ -40,13 +40,13 @@ type Finder struct {
}
// NewFinder creates a new finder.
-func NewFinder(database *storepb.DatabaseMetadata, ctx *FinderContext) *Finder {
+func NewFinder(database *storepb.DatabaseSchemaMetadata, ctx *FinderContext) *Finder {
return &Finder{Origin: newDatabaseState(database, ctx), Final: newDatabaseState(database, ctx)}
}
// NewEmptyFinder creates a finder with empty databse.
func NewEmptyFinder(ctx *FinderContext) *Finder {
- return &Finder{Origin: newDatabaseState(&storepb.DatabaseMetadata{}, ctx), Final: newDatabaseState(&storepb.DatabaseMetadata{}, ctx)}
+ return &Finder{Origin: newDatabaseState(&storepb.DatabaseSchemaMetadata{}, ctx), Final: newDatabaseState(&storepb.DatabaseSchemaMetadata{}, ctx)}
}
// WalkThrough does the walk through.
diff --git a/backend/plugin/advisor/catalog/state.go b/backend/plugin/advisor/catalog/state.go
index 127cc33e64..44e96ed224 100644
--- a/backend/plugin/advisor/catalog/state.go
+++ b/backend/plugin/advisor/catalog/state.go
@@ -12,7 +12,7 @@ import (
storepb "github.com/bytebase/bytebase/proto/generated-go/store"
)
-func newDatabaseState(d *storepb.DatabaseMetadata, context *FinderContext) *DatabaseState {
+func newDatabaseState(d *storepb.DatabaseSchemaMetadata, context *FinderContext) *DatabaseState {
database := &DatabaseState{
ctx: context.Copy(),
name: d.Name,
diff --git a/backend/plugin/advisor/catalog/walk_through_test.go b/backend/plugin/advisor/catalog/walk_through_test.go
index 6f51862a19..e36ac0731f 100644
--- a/backend/plugin/advisor/catalog/walk_through_test.go
+++ b/backend/plugin/advisor/catalog/walk_through_test.go
@@ -23,12 +23,12 @@ import (
type testData struct {
Statement string
- Want *storepb.DatabaseMetadata
+ Want *storepb.DatabaseSchemaMetadata
Err *WalkThroughError
}
func TestMySQLWalkThrough(t *testing.T) {
- originDatabase := &storepb.DatabaseMetadata{
+ originDatabase := &storepb.DatabaseSchemaMetadata{
Name: "test",
}
@@ -52,7 +52,7 @@ func TestMySQLWalkThroughForIncomplete(t *testing.T) {
}
func TestPostgreSQLWalkThrough(t *testing.T) {
- originDatabase := &storepb.DatabaseMetadata{
+ originDatabase := &storepb.DatabaseSchemaMetadata{
Name: "postgres",
Schemas: []*storepb.SchemaMetadata{
{
@@ -113,7 +113,7 @@ func convertInterfaceSliceToStringSlice(slice []any) []string {
return res
}
-func runWalkThroughTest(t *testing.T, file string, engineType db.Type, originDatabase *storepb.DatabaseMetadata, record bool) {
+func runWalkThroughTest(t *testing.T, file string, engineType db.Type, originDatabase *storepb.DatabaseSchemaMetadata, record bool) {
tests := []testData{}
filepath := filepath.Join("test", file+".yaml")
yamlFile, err := os.Open(filepath)
@@ -175,11 +175,11 @@ func runWalkThroughTest(t *testing.T, file string, engineType db.Type, originDat
}
// convertToDatabaseMetadata only used for tests.
-func (d *DatabaseState) convertToDatabaseMetadata() *storepb.DatabaseMetadata {
+func (d *DatabaseState) convertToDatabaseMetadata() *storepb.DatabaseSchemaMetadata {
if d.deleted {
return nil
}
- return &storepb.DatabaseMetadata{
+ return &storepb.DatabaseSchemaMetadata{
Name: d.name,
CharacterSet: d.characterSet,
Collation: d.collation,
diff --git a/backend/plugin/advisor/utils_for_tests.go b/backend/plugin/advisor/utils_for_tests.go
index 3e25ec79ff..0a52cbcd6b 100644
--- a/backend/plugin/advisor/utils_for_tests.go
+++ b/backend/plugin/advisor/utils_for_tests.go
@@ -44,7 +44,7 @@ var (
// MockIndexColumnList is the mock index column list for test.
MockIndexColumnList = []string{"id", "name"}
// MockMySQLDatabase is the mock MySQL database for test.
- MockMySQLDatabase = &storepb.DatabaseMetadata{
+ MockMySQLDatabase = &storepb.DatabaseSchemaMetadata{
Name: "test",
Schemas: []*storepb.SchemaMetadata{
{
@@ -84,7 +84,7 @@ var (
},
}
// MockPostgreSQLDatabase is the mock PostgreSQL database for test.
- MockPostgreSQLDatabase = &storepb.DatabaseMetadata{
+ MockPostgreSQLDatabase = &storepb.DatabaseSchemaMetadata{
Name: "test",
Schemas: []*storepb.SchemaMetadata{
{
@@ -261,7 +261,7 @@ func (*MockDriver) SyncInstance(_ context.Context) (*database.InstanceMetadata,
}
// SyncDBSchema implements the Driver interface.
-func (*MockDriver) SyncDBSchema(_ context.Context) (*storepb.DatabaseMetadata, error) {
+func (*MockDriver) SyncDBSchema(_ context.Context) (*storepb.DatabaseSchemaMetadata, error) {
return nil, nil
}
diff --git a/backend/plugin/db/clickhouse/sync.go b/backend/plugin/db/clickhouse/sync.go
index 631667d07e..ced14598c9 100644
--- a/backend/plugin/db/clickhouse/sync.go
+++ b/backend/plugin/db/clickhouse/sync.go
@@ -37,7 +37,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
excludedDatabases = append(excludedDatabases, fmt.Sprintf("'%s'", k))
}
- var databases []*storepb.DatabaseMetadata
+ var databases []*storepb.DatabaseSchemaMetadata
// Query db info
where := fmt.Sprintf("name NOT IN (%s)", strings.Join(excludedDatabases, ", "))
query := `
@@ -51,7 +51,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}
defer rows.Close()
for rows.Next() {
- database := &storepb.DatabaseMetadata{}
+ database := &storepb.DatabaseSchemaMetadata{}
if err := rows.Scan(
&database.Name,
); err != nil {
@@ -71,7 +71,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}
// SyncDBSchema syncs a single database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
schemaMetadata := &storepb.SchemaMetadata{
Name: "",
}
@@ -172,7 +172,7 @@ func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetada
return nil, util.FormatErrorWithQuery(err, tableQuery)
}
- return &storepb.DatabaseMetadata{
+ return &storepb.DatabaseSchemaMetadata{
Name: driver.databaseName,
Schemas: []*storepb.SchemaMetadata{schemaMetadata},
}, nil
diff --git a/backend/plugin/db/dm/sync.go b/backend/plugin/db/dm/sync.go
index ca01768ed4..6e6d7d4b3f 100644
--- a/backend/plugin/db/dm/sync.go
+++ b/backend/plugin/db/dm/sync.go
@@ -38,7 +38,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}, nil
}
-func (driver *Driver) syncSchemaTenantModeInstance(ctx context.Context) ([]*storepb.DatabaseMetadata, error) {
+func (driver *Driver) syncSchemaTenantModeInstance(ctx context.Context) ([]*storepb.DatabaseSchemaMetadata, error) {
txn, err := driver.db.BeginTx(ctx, nil)
if err != nil {
return nil, err
@@ -50,10 +50,10 @@ func (driver *Driver) syncSchemaTenantModeInstance(ctx context.Context) ([]*stor
return nil, err
}
- var result []*storepb.DatabaseMetadata
+ var result []*storepb.DatabaseSchemaMetadata
for _, schema := range schemas {
- result = append(result, &storepb.DatabaseMetadata{
+ result = append(result, &storepb.DatabaseSchemaMetadata{
Name: schema,
ServiceName: "",
})
@@ -63,7 +63,7 @@ func (driver *Driver) syncSchemaTenantModeInstance(ctx context.Context) ([]*stor
}
// SyncDBSchema syncs a single database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
txn, err := driver.db.BeginTx(ctx, nil)
if err != nil {
return nil, err
@@ -83,7 +83,7 @@ func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetada
return nil, err
}
- databaseMetadata := &storepb.DatabaseMetadata{
+ databaseMetadata := &storepb.DatabaseSchemaMetadata{
Name: driver.databaseName,
}
databaseMetadata.Schemas = append(databaseMetadata.Schemas, &storepb.SchemaMetadata{
diff --git a/backend/plugin/db/driver.go b/backend/plugin/db/driver.go
index 6ee88fd730..c515817531 100644
--- a/backend/plugin/db/driver.go
+++ b/backend/plugin/db/driver.go
@@ -77,7 +77,7 @@ type InstanceMetadata struct {
Version string
InstanceRoles []*storepb.InstanceRoleMetadata
// Simplified database metadata.
- Databases []*storepb.DatabaseMetadata
+ Databases []*storepb.DatabaseSchemaMetadata
Metadata *storepb.InstanceMetadata
}
@@ -519,7 +519,7 @@ type Driver interface {
// SyncInstance syncs the instance metadata.
SyncInstance(ctx context.Context) (*InstanceMetadata, error)
// SyncDBSchema syncs a single database schema.
- SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error)
+ SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error)
// Sync slow query logs
// SyncSlowQuery syncs the slow query logs.
diff --git a/backend/plugin/db/mongodb/sync.go b/backend/plugin/db/mongodb/sync.go
index 7437c16585..5fa6964feb 100644
--- a/backend/plugin/db/mongodb/sync.go
+++ b/backend/plugin/db/mongodb/sync.go
@@ -62,13 +62,13 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
if err != nil {
return nil, err
}
- var databases []*storepb.DatabaseMetadata
+ var databases []*storepb.DatabaseSchemaMetadata
databaseNames, err := driver.getNonSystemDatabaseList(ctx)
if err != nil {
return nil, err
}
for _, databaseName := range databaseNames {
- databases = append(databases, &storepb.DatabaseMetadata{
+ databases = append(databases, &storepb.DatabaseSchemaMetadata{
Name: databaseName,
})
}
@@ -81,7 +81,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}
// SyncDBSchema syncs the database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
schemaMetadata := &storepb.SchemaMetadata{
Name: "",
}
@@ -159,7 +159,7 @@ func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetada
schemaMetadata.Views = append(schemaMetadata.Views, &storepb.ViewMetadata{Name: viewName})
}
- return &storepb.DatabaseMetadata{
+ return &storepb.DatabaseSchemaMetadata{
Name: driver.databaseName,
Schemas: []*storepb.SchemaMetadata{schemaMetadata},
}, nil
diff --git a/backend/plugin/db/mssql/sync.go b/backend/plugin/db/mssql/sync.go
index 339f5ffe56..c02b4c1141 100644
--- a/backend/plugin/db/mssql/sync.go
+++ b/backend/plugin/db/mssql/sync.go
@@ -30,7 +30,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}
}
- var databases []*storepb.DatabaseMetadata
+ var databases []*storepb.DatabaseSchemaMetadata
rows, err := driver.db.QueryContext(ctx, "SELECT name, collation_name FROM master.sys.databases WHERE name NOT IN ('master', 'model', 'msdb', 'tempdb', 'rdscore')")
if err != nil {
return nil, err
@@ -38,7 +38,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
defer rows.Close()
for rows.Next() {
- database := &storepb.DatabaseMetadata{}
+ database := &storepb.DatabaseSchemaMetadata{}
var collation sql.NullString
if err := rows.Scan(&database.Name, &collation); err != nil {
return nil, err
@@ -59,7 +59,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}
// SyncDBSchema syncs a single database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
txn, err := driver.db.BeginTx(ctx, nil)
if err != nil {
return nil, err
@@ -83,7 +83,7 @@ func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetada
return nil, err
}
- databaseMetadata := &storepb.DatabaseMetadata{
+ databaseMetadata := &storepb.DatabaseSchemaMetadata{
Name: driver.databaseName,
}
for _, schemaName := range schemaNames {
diff --git a/backend/plugin/db/mysql/sync.go b/backend/plugin/db/mysql/sync.go
index f3af121b60..bf9e969dd7 100644
--- a/backend/plugin/db/mysql/sync.go
+++ b/backend/plugin/db/mysql/sync.go
@@ -89,9 +89,9 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}
defer rows.Close()
- var databases []*storepb.DatabaseMetadata
+ var databases []*storepb.DatabaseSchemaMetadata
for rows.Next() {
- database := &storepb.DatabaseMetadata{}
+ database := &storepb.DatabaseSchemaMetadata{}
if err := rows.Scan(
&database.Name,
&database.CharacterSet,
@@ -116,7 +116,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}
// SyncDBSchema syncs a single database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
schemaMetadata := &storepb.SchemaMetadata{
Name: "",
}
@@ -381,7 +381,7 @@ func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetada
return nil, util.FormatErrorWithQuery(err, tableQuery)
}
- databaseMetadata := &storepb.DatabaseMetadata{
+ databaseMetadata := &storepb.DatabaseSchemaMetadata{
Name: driver.databaseName,
Schemas: []*storepb.SchemaMetadata{schemaMetadata},
}
diff --git a/backend/plugin/db/oracle/sync.go b/backend/plugin/db/oracle/sync.go
index 72a21c5744..a0a2744340 100644
--- a/backend/plugin/db/oracle/sync.go
+++ b/backend/plugin/db/oracle/sync.go
@@ -57,7 +57,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}, nil
}
- var databases []*storepb.DatabaseMetadata
+ var databases []*storepb.DatabaseSchemaMetadata
// sync CDB
cdbRows, err := driver.db.QueryContext(ctx, "SELECT name FROM v$database")
if err != nil {
@@ -66,7 +66,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
defer cdbRows.Close()
for cdbRows.Next() {
- database := &storepb.DatabaseMetadata{}
+ database := &storepb.DatabaseSchemaMetadata{}
if err := cdbRows.Scan(&database.Name); err != nil {
return nil, err
}
@@ -95,7 +95,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
defer rows.Close()
for rows.Next() {
- database := &storepb.DatabaseMetadata{}
+ database := &storepb.DatabaseSchemaMetadata{}
if err := rows.Scan(&database.Name, &database.ServiceName); err != nil {
return nil, err
}
@@ -111,7 +111,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}, nil
}
-func (driver *Driver) syncSchemaTenantModeInstance(ctx context.Context) ([]*storepb.DatabaseMetadata, error) {
+func (driver *Driver) syncSchemaTenantModeInstance(ctx context.Context) ([]*storepb.DatabaseSchemaMetadata, error) {
txn, err := driver.db.BeginTx(ctx, nil)
if err != nil {
return nil, err
@@ -123,10 +123,10 @@ func (driver *Driver) syncSchemaTenantModeInstance(ctx context.Context) ([]*stor
return nil, err
}
- var result []*storepb.DatabaseMetadata
+ var result []*storepb.DatabaseSchemaMetadata
for _, schema := range schemas {
- result = append(result, &storepb.DatabaseMetadata{
+ result = append(result, &storepb.DatabaseSchemaMetadata{
Name: schema,
ServiceName: "",
})
@@ -136,7 +136,7 @@ func (driver *Driver) syncSchemaTenantModeInstance(ctx context.Context) ([]*stor
}
// SyncDBSchema syncs a single database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
if driver.schemaTenantMode {
return driver.syncSchemaTenantModeDBSchema(ctx)
}
@@ -164,7 +164,7 @@ func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetada
return nil, err
}
- databaseMetadata := &storepb.DatabaseMetadata{
+ databaseMetadata := &storepb.DatabaseSchemaMetadata{
Name: driver.databaseName,
ServiceName: driver.serviceName,
}
@@ -178,7 +178,7 @@ func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetada
return databaseMetadata, nil
}
-func (driver *Driver) syncSchemaTenantModeDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) syncSchemaTenantModeDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
txn, err := driver.db.BeginTx(ctx, nil)
if err != nil {
return nil, err
@@ -198,7 +198,7 @@ func (driver *Driver) syncSchemaTenantModeDBSchema(ctx context.Context) (*storep
return nil, err
}
- databaseMetadata := &storepb.DatabaseMetadata{
+ databaseMetadata := &storepb.DatabaseSchemaMetadata{
Name: driver.databaseName,
ServiceName: driver.serviceName,
}
diff --git a/backend/plugin/db/pg/pg.go b/backend/plugin/db/pg/pg.go
index e3c6608441..7fa303132c 100644
--- a/backend/plugin/db/pg/pg.go
+++ b/backend/plugin/db/pg/pg.go
@@ -216,8 +216,8 @@ func (driver *Driver) GetDB() *sql.DB {
}
// getDatabases gets all databases of an instance.
-func (driver *Driver) getDatabases(ctx context.Context) ([]*storepb.DatabaseMetadata, error) {
- var databases []*storepb.DatabaseMetadata
+func (driver *Driver) getDatabases(ctx context.Context) ([]*storepb.DatabaseSchemaMetadata, error) {
+ var databases []*storepb.DatabaseSchemaMetadata
rows, err := driver.db.QueryContext(ctx, "SELECT datname, pg_encoding_to_char(encoding), datcollate FROM pg_database;")
if err != nil {
return nil, err
@@ -225,7 +225,7 @@ func (driver *Driver) getDatabases(ctx context.Context) ([]*storepb.DatabaseMeta
defer rows.Close()
for rows.Next() {
- database := &storepb.DatabaseMetadata{}
+ database := &storepb.DatabaseSchemaMetadata{}
if err := rows.Scan(&database.Name, &database.CharacterSet, &database.Collation); err != nil {
return nil, err
}
diff --git a/backend/plugin/db/pg/sync.go b/backend/plugin/db/pg/sync.go
index 109b837c5c..d2913bf24a 100644
--- a/backend/plugin/db/pg/sync.go
+++ b/backend/plugin/db/pg/sync.go
@@ -42,7 +42,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
return nil, errors.Wrap(err, "failed to get databases")
}
- var filteredDatabases []*storepb.DatabaseMetadata
+ var filteredDatabases []*storepb.DatabaseSchemaMetadata
for _, database := range databases {
// Skip all system databases
if _, ok := ExcludedDatabaseList[database.Name]; ok {
@@ -59,14 +59,14 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}
// SyncDBSchema syncs a single database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
// Query db info
databases, err := driver.getDatabases(ctx)
if err != nil {
return nil, errors.Wrap(err, "failed to get databases")
}
- var databaseMetadata *storepb.DatabaseMetadata
+ var databaseMetadata *storepb.DatabaseSchemaMetadata
for _, database := range databases {
if database.Name == driver.databaseName {
databaseMetadata = database
diff --git a/backend/plugin/db/redis/sync.go b/backend/plugin/db/redis/sync.go
index 2c8bcf6d5c..47afef90e4 100644
--- a/backend/plugin/db/redis/sync.go
+++ b/backend/plugin/db/redis/sync.go
@@ -41,9 +41,9 @@ func (d *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, error)
databaseCount = count
}
- var databases []*storepb.DatabaseMetadata
+ var databases []*storepb.DatabaseSchemaMetadata
for i := 0; i < databaseCount; i++ {
- databases = append(databases, &storepb.DatabaseMetadata{
+ databases = append(databases, &storepb.DatabaseSchemaMetadata{
Name: strconv.Itoa(i),
})
}
@@ -53,8 +53,8 @@ func (d *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, error)
}
// SyncDBSchema syncs a single database schema.
-func (d *Driver) SyncDBSchema(context.Context) (*storepb.DatabaseMetadata, error) {
- return &storepb.DatabaseMetadata{Name: d.databaseName}, nil
+func (d *Driver) SyncDBSchema(context.Context) (*storepb.DatabaseSchemaMetadata, error) {
+ return &storepb.DatabaseSchemaMetadata{Name: d.databaseName}, nil
}
func (d *Driver) getVersion(ctx context.Context) (string, error) {
diff --git a/backend/plugin/db/redshift/sync.go b/backend/plugin/db/redshift/sync.go
index 7e42a91761..f0941186e0 100644
--- a/backend/plugin/db/redshift/sync.go
+++ b/backend/plugin/db/redshift/sync.go
@@ -39,7 +39,7 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
return nil, errors.Wrap(err, "failed to get databases")
}
- var filteredDatabases []*storepb.DatabaseMetadata
+ var filteredDatabases []*storepb.DatabaseSchemaMetadata
for _, database := range databases {
// Skip all system databases
if _, ok := excludedDatabaseList[database.Name]; ok {
@@ -134,14 +134,14 @@ func (driver *Driver) getInstanceRoles(ctx context.Context) ([]*storepb.Instance
}
// SyncDBSchema syncs a single database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
// Query db info
databases, err := driver.getDatabases(ctx)
if err != nil {
return nil, errors.Wrap(err, "failed to get databases")
}
- var databaseMetadata *storepb.DatabaseMetadata
+ var databaseMetadata *storepb.DatabaseSchemaMetadata
for _, database := range databases {
if database.Name == driver.databaseName {
databaseMetadata = database
@@ -790,7 +790,7 @@ func buildRedshiftVersionString(redshiftVersion, postgresVersion string) string
}
// getDatabases gets all databases of an instance.
-func (driver *Driver) getDatabases(ctx context.Context) ([]*storepb.DatabaseMetadata, error) {
+func (driver *Driver) getDatabases(ctx context.Context) ([]*storepb.DatabaseSchemaMetadata, error) {
consumerDatabases := make(map[string]bool)
dsRows, err := driver.db.QueryContext(ctx, `
SELECT consumer_database FROM SVV_DATASHARES WHERE share_type = 'INBOUND';
@@ -811,7 +811,7 @@ func (driver *Driver) getDatabases(ctx context.Context) ([]*storepb.DatabaseMeta
return nil, err
}
- var databases []*storepb.DatabaseMetadata
+ var databases []*storepb.DatabaseSchemaMetadata
rows, err := driver.db.QueryContext(ctx, `
SELECT datname,
pg_encoding_to_char(encoding)
@@ -823,7 +823,7 @@ func (driver *Driver) getDatabases(ctx context.Context) ([]*storepb.DatabaseMeta
defer rows.Close()
for rows.Next() {
- database := storepb.DatabaseMetadata{}
+ database := storepb.DatabaseSchemaMetadata{}
if err := rows.Scan(&database.Name, &database.CharacterSet); err != nil {
return nil, err
}
diff --git a/backend/plugin/db/snowflake/sync.go b/backend/plugin/db/snowflake/sync.go
index 780540bed3..6578d208a4 100644
--- a/backend/plugin/db/snowflake/sync.go
+++ b/backend/plugin/db/snowflake/sync.go
@@ -44,12 +44,12 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
return nil, err
}
- var filteredDatabases []*storepb.DatabaseMetadata
+ var filteredDatabases []*storepb.DatabaseSchemaMetadata
for _, database := range databases {
if database == bytebaseDatabase {
continue
}
- filteredDatabases = append(filteredDatabases, &storepb.DatabaseMetadata{Name: database})
+ filteredDatabases = append(filteredDatabases, &storepb.DatabaseSchemaMetadata{Name: database})
}
return &db.InstanceMetadata{
@@ -60,14 +60,14 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
}
// SyncDBSchema syncs a single database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
// Query db info
databases, err := driver.getDatabases(ctx)
if err != nil {
return nil, err
}
- databaseMetadata := &storepb.DatabaseMetadata{
+ databaseMetadata := &storepb.DatabaseSchemaMetadata{
Name: driver.databaseName,
}
found := false
diff --git a/backend/plugin/db/spanner/sync.go b/backend/plugin/db/spanner/sync.go
index 4239d81ae1..f922337ed3 100644
--- a/backend/plugin/db/spanner/sync.go
+++ b/backend/plugin/db/spanner/sync.go
@@ -21,7 +21,7 @@ import (
// SyncInstance syncs the instance.
func (d *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, error) {
- var databases []*storepb.DatabaseMetadata
+ var databases []*storepb.DatabaseSchemaMetadata
iter := d.dbClient.ListDatabases(ctx, &databasepb.ListDatabasesRequest{
Parent: d.config.Host,
})
@@ -50,7 +50,7 @@ func (d *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, error)
continue
}
- databases = append(databases, &storepb.DatabaseMetadata{Name: databaseName})
+ databases = append(databases, &storepb.DatabaseSchemaMetadata{Name: databaseName})
}
return &db.InstanceMetadata{
@@ -59,7 +59,7 @@ func (d *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, error)
}
// SyncDBSchema syncs a single database schema.
-func (d *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (d *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
notFound, err := d.notFoundDatabase(ctx, d.databaseName)
if err != nil {
return nil, errors.Wrap(err, "failed to check if database exists")
@@ -71,7 +71,7 @@ func (d *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, e
tx := d.client.ReadOnlyTransaction()
defer tx.Close()
- databaseMetadata := &storepb.DatabaseMetadata{
+ databaseMetadata := &storepb.DatabaseSchemaMetadata{
Name: d.databaseName,
}
tableMap, err := getTable(ctx, tx)
diff --git a/backend/plugin/db/sqlite/sync.go b/backend/plugin/db/sqlite/sync.go
index 5bc0d26cbc..d61301952d 100644
--- a/backend/plugin/db/sqlite/sync.go
+++ b/backend/plugin/db/sqlite/sync.go
@@ -35,12 +35,12 @@ func (driver *Driver) SyncInstance(ctx context.Context) (*db.InstanceMetadata, e
return nil, err
}
- var databases []*storepb.DatabaseMetadata
+ var databases []*storepb.DatabaseSchemaMetadata
for _, databaseName := range databaseNames {
if _, ok := excludedDatabaseList[databaseName]; ok {
continue
}
- databases = append(databases, &storepb.DatabaseMetadata{Name: databaseName})
+ databases = append(databases, &storepb.DatabaseSchemaMetadata{Name: databaseName})
}
return &db.InstanceMetadata{
@@ -59,7 +59,7 @@ func (driver *Driver) getVersion(ctx context.Context) (string, error) {
}
// SyncDBSchema syncs a single database schema.
-func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetadata, error) {
+func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseSchemaMetadata, error) {
databases, err := driver.getDatabases()
if err != nil {
return nil, err
@@ -68,7 +68,7 @@ func (driver *Driver) SyncDBSchema(ctx context.Context) (*storepb.DatabaseMetada
schemaMetadata := &storepb.SchemaMetadata{
Name: "",
}
- databaseMetadata := &storepb.DatabaseMetadata{
+ databaseMetadata := &storepb.DatabaseSchemaMetadata{
Name: driver.databaseName,
Schemas: []*storepb.SchemaMetadata{schemaMetadata},
}
diff --git a/backend/runner/schemasync/syncer.go b/backend/runner/schemasync/syncer.go
index 035531696f..5b4975b7e5 100644
--- a/backend/runner/schemasync/syncer.go
+++ b/backend/runner/schemasync/syncer.go
@@ -315,12 +315,12 @@ func (s *Syncer) SyncDatabaseSchema(ctx context.Context, database *store.Databas
return syncDBSchema(ctx, s.store, database, databaseMetadata, driver, force)
}
-func syncDBSchema(ctx context.Context, stores *store.Store, database *store.DatabaseMessage, databaseMetadata *storepb.DatabaseMetadata, driver db.Driver, force bool) error {
+func syncDBSchema(ctx context.Context, stores *store.Store, database *store.DatabaseMessage, databaseMetadata *storepb.DatabaseSchemaMetadata, driver db.Driver, force bool) error {
dbSchema, err := stores.GetDBSchema(ctx, database.UID)
if err != nil {
return err
}
- var oldDatabaseMetadata *storepb.DatabaseMetadata
+ var oldDatabaseMetadata *storepb.DatabaseSchemaMetadata
if dbSchema != nil {
oldDatabaseMetadata = dbSchema.Metadata
}
@@ -350,13 +350,13 @@ func syncDBSchema(ctx context.Context, stores *store.Store, database *store.Data
return nil
}
-func equalDatabaseMetadata(x, y *storepb.DatabaseMetadata) bool {
+func equalDatabaseMetadata(x, y *storepb.DatabaseSchemaMetadata) bool {
return cmp.Equal(x, y, protocmp.Transform(),
protocmp.IgnoreFields(&storepb.TableMetadata{}, "row_count", "data_size", "index_size", "data_free"),
)
}
-func setClassificationAndUserCommentFromComment(dbSchema *storepb.DatabaseMetadata) {
+func setClassificationAndUserCommentFromComment(dbSchema *storepb.DatabaseSchemaMetadata) {
for _, schema := range dbSchema.Schemas {
for _, table := range schema.Tables {
table.Classification, table.UserComment = common.GetClassificationAndUserComment(table.Comment)
diff --git a/backend/runner/schemasync/syncer_test.go b/backend/runner/schemasync/syncer_test.go
index 0cc471767a..6aebe5c78e 100644
--- a/backend/runner/schemasync/syncer_test.go
+++ b/backend/runner/schemasync/syncer_test.go
@@ -10,31 +10,31 @@ import (
func TestEqualDatabaseMetadata(t *testing.T) {
tests := []struct {
- x *storepb.DatabaseMetadata
- y *storepb.DatabaseMetadata
+ x *storepb.DatabaseSchemaMetadata
+ y *storepb.DatabaseSchemaMetadata
want bool
}{
{
- x: &storepb.DatabaseMetadata{},
- y: &storepb.DatabaseMetadata{},
+ x: &storepb.DatabaseSchemaMetadata{},
+ y: &storepb.DatabaseSchemaMetadata{},
want: true,
},
{
x: nil,
- y: &storepb.DatabaseMetadata{},
+ y: &storepb.DatabaseSchemaMetadata{},
want: false,
},
{
- x: &storepb.DatabaseMetadata{
+ x: &storepb.DatabaseSchemaMetadata{
Name: "hello",
},
- y: &storepb.DatabaseMetadata{
+ y: &storepb.DatabaseSchemaMetadata{
Name: "world",
},
want: false,
},
{
- x: &storepb.DatabaseMetadata{
+ x: &storepb.DatabaseSchemaMetadata{
Name: "hello",
Schemas: []*storepb.SchemaMetadata{
{
@@ -47,7 +47,7 @@ func TestEqualDatabaseMetadata(t *testing.T) {
},
},
},
- y: &storepb.DatabaseMetadata{
+ y: &storepb.DatabaseSchemaMetadata{
Name: "hello",
Schemas: []*storepb.SchemaMetadata{
{
@@ -63,7 +63,7 @@ func TestEqualDatabaseMetadata(t *testing.T) {
want: true,
},
{
- x: &storepb.DatabaseMetadata{
+ x: &storepb.DatabaseSchemaMetadata{
Name: "hello",
Schemas: []*storepb.SchemaMetadata{
{
@@ -76,7 +76,7 @@ func TestEqualDatabaseMetadata(t *testing.T) {
},
},
},
- y: &storepb.DatabaseMetadata{
+ y: &storepb.DatabaseSchemaMetadata{
Name: "hello",
Schemas: []*storepb.SchemaMetadata{
{
@@ -92,7 +92,7 @@ func TestEqualDatabaseMetadata(t *testing.T) {
want: false,
},
{
- x: &storepb.DatabaseMetadata{
+ x: &storepb.DatabaseSchemaMetadata{
Name: "hello",
Schemas: []*storepb.SchemaMetadata{
{
@@ -109,7 +109,7 @@ func TestEqualDatabaseMetadata(t *testing.T) {
},
},
},
- y: &storepb.DatabaseMetadata{
+ y: &storepb.DatabaseSchemaMetadata{
Name: "hello",
Schemas: []*storepb.SchemaMetadata{
{
diff --git a/backend/store/db_schema.go b/backend/store/db_schema.go
index 69bd9984f4..539d009dd8 100644
--- a/backend/store/db_schema.go
+++ b/backend/store/db_schema.go
@@ -14,7 +14,7 @@ import (
// DBSchema is the database schema including the metadata and schema (raw dump).
type DBSchema struct {
- Metadata *storepb.DatabaseMetadata
+ Metadata *storepb.DatabaseSchemaMetadata
Schema []byte
}
@@ -175,7 +175,7 @@ func (s *Store) GetDBSchema(ctx context.Context, databaseID int) (*DBSchema, err
return nil, err
}
- var databaseSchema storepb.DatabaseMetadata
+ var databaseSchema storepb.DatabaseSchemaMetadata
decoder := protojson.UnmarshalOptions{DiscardUnknown: true}
if err := decoder.Unmarshal(metadata, &databaseSchema); err != nil {
return nil, err
diff --git a/frontend/src/types/proto/store/database.ts b/frontend/src/types/proto/store/database.ts
index 87d5528abb..1085f5344f 100644
--- a/frontend/src/types/proto/store/database.ts
+++ b/frontend/src/types/proto/store/database.ts
@@ -7,6 +7,16 @@ export const protobufPackage = "bytebase.store";
/** DatabaseMetadata is the metadata for databases. */
export interface DatabaseMetadata {
+ labels: { [key: string]: string };
+}
+
+export interface DatabaseMetadata_LabelsEntry {
+ key: string;
+ value: string;
+}
+
+/** DatabaseSchemaMetadata is the schema metadata for databases. */
+export interface DatabaseSchemaMetadata {
name: string;
/** The schemas is the list of schemas in a database. */
schemas: SchemaMetadata[];
@@ -383,11 +393,155 @@ export interface SecretItem {
}
function createBaseDatabaseMetadata(): DatabaseMetadata {
- return { name: "", schemas: [], characterSet: "", collation: "", extensions: [], datashare: false, serviceName: "" };
+ return { labels: {} };
}
export const DatabaseMetadata = {
encode(message: DatabaseMetadata, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
+ Object.entries(message.labels).forEach(([key, value]) => {
+ DatabaseMetadata_LabelsEntry.encode({ key: key as any, value }, writer.uint32(10).fork()).ldelim();
+ });
+ return writer;
+ },
+
+ decode(input: _m0.Reader | Uint8Array, length?: number): DatabaseMetadata {
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
+ let end = length === undefined ? reader.len : reader.pos + length;
+ const message = createBaseDatabaseMetadata();
+ while (reader.pos < end) {
+ const tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1:
+ if (tag !== 10) {
+ break;
+ }
+
+ const entry1 = DatabaseMetadata_LabelsEntry.decode(reader, reader.uint32());
+ if (entry1.value !== undefined) {
+ message.labels[entry1.key] = entry1.value;
+ }
+ continue;
+ }
+ if ((tag & 7) === 4 || tag === 0) {
+ break;
+ }
+ reader.skipType(tag & 7);
+ }
+ return message;
+ },
+
+ fromJSON(object: any): DatabaseMetadata {
+ return {
+ labels: isObject(object.labels)
+ ? Object.entries(object.labels).reduce<{ [key: string]: string }>((acc, [key, value]) => {
+ acc[key] = String(value);
+ return acc;
+ }, {})
+ : {},
+ };
+ },
+
+ toJSON(message: DatabaseMetadata): unknown {
+ const obj: any = {};
+ obj.labels = {};
+ if (message.labels) {
+ Object.entries(message.labels).forEach(([k, v]) => {
+ obj.labels[k] = v;
+ });
+ }
+ return obj;
+ },
+
+ create(base?: DeepPartial<DatabaseMetadata>): DatabaseMetadata {
+ return DatabaseMetadata.fromPartial(base ?? {});
+ },
+
+ fromPartial(object: DeepPartial<DatabaseMetadata>): DatabaseMetadata {
+ const message = createBaseDatabaseMetadata();
+ message.labels = Object.entries(object.labels ?? {}).reduce<{ [key: string]: string }>((acc, [key, value]) => {
+ if (value !== undefined) {
+ acc[key] = String(value);
+ }
+ return acc;
+ }, {});
+ return message;
+ },
+};
+
+function createBaseDatabaseMetadata_LabelsEntry(): DatabaseMetadata_LabelsEntry {
+ return { key: "", value: "" };
+}
+
+export const DatabaseMetadata_LabelsEntry = {
+ encode(message: DatabaseMetadata_LabelsEntry, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
+ if (message.key !== "") {
+ writer.uint32(10).string(message.key);
+ }
+ if (message.value !== "") {
+ writer.uint32(18).string(message.value);
+ }
+ return writer;
+ },
+
+ decode(input: _m0.Reader | Uint8Array, length?: number): DatabaseMetadata_LabelsEntry {
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
+ let end = length === undefined ? reader.len : reader.pos + length;
+ const message = createBaseDatabaseMetadata_LabelsEntry();
+ while (reader.pos < end) {
+ const tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1:
+ if (tag !== 10) {
+ break;
+ }
+
+ message.key = reader.string();
+ continue;
+ case 2:
+ if (tag !== 18) {
+ break;
+ }
+
+ message.value = reader.string();
+ continue;
+ }
+ if ((tag & 7) === 4 || tag === 0) {
+ break;
+ }
+ reader.skipType(tag & 7);
+ }
+ return message;
+ },
+
+ fromJSON(object: any): DatabaseMetadata_LabelsEntry {
+ return { key: isSet(object.key) ? String(object.key) : "", value: isSet(object.value) ? String(object.value) : "" };
+ },
+
+ toJSON(message: DatabaseMetadata_LabelsEntry): unknown {
+ const obj: any = {};
+ message.key !== undefined && (obj.key = message.key);
+ message.value !== undefined && (obj.value = message.value);
+ return obj;
+ },
+
+ create(base?: DeepPartial<DatabaseMetadata_LabelsEntry>): DatabaseMetadata_LabelsEntry {
+ return DatabaseMetadata_LabelsEntry.fromPartial(base ?? {});
+ },
+
+ fromPartial(object: DeepPartial<DatabaseMetadata_LabelsEntry>): DatabaseMetadata_LabelsEntry {
+ const message = createBaseDatabaseMetadata_LabelsEntry();
+ message.key = object.key ?? "";
+ message.value = object.value ?? "";
+ return message;
+ },
+};
+
+function createBaseDatabaseSchemaMetadata(): DatabaseSchemaMetadata {
+ return { name: "", schemas: [], characterSet: "", collation: "", extensions: [], datashare: false, serviceName: "" };
+}
+
+export const DatabaseSchemaMetadata = {
+ encode(message: DatabaseSchemaMetadata, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
if (message.name !== "") {
writer.uint32(10).string(message.name);
}
@@ -412,10 +566,10 @@ export const DatabaseMetadata = {
return writer;
},
- decode(input: _m0.Reader | Uint8Array, length?: number): DatabaseMetadata {
+ decode(input: _m0.Reader | Uint8Array, length?: number): DatabaseSchemaMetadata {
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
let end = length === undefined ? reader.len : reader.pos + length;
- const message = createBaseDatabaseMetadata();
+ const message = createBaseDatabaseSchemaMetadata();
while (reader.pos < end) {
const tag = reader.uint32();
switch (tag >>> 3) {
@@ -477,7 +631,7 @@ export const DatabaseMetadata = {
return message;
},
- fromJSON(object: any): DatabaseMetadata {
+ fromJSON(object: any): DatabaseSchemaMetadata {
return {
name: isSet(object.name) ? String(object.name) : "",
schemas: Array.isArray(object?.schemas) ? object.schemas.map((e: any) => SchemaMetadata.fromJSON(e)) : [],
@@ -491,7 +645,7 @@ export const DatabaseMetadata = {
};
},
- toJSON(message: DatabaseMetadata): unknown {
+ toJSON(message: DatabaseSchemaMetadata): unknown {
const obj: any = {};
message.name !== undefined && (obj.name = message.name);
if (message.schemas) {
@@ -511,12 +665,12 @@ export const DatabaseMetadata = {
return obj;
},
- create(base?: DeepPartial<DatabaseMetadata>): DatabaseMetadata {
- return DatabaseMetadata.fromPartial(base ?? {});
+ create(base?: DeepPartial<DatabaseSchemaMetadata>): DatabaseSchemaMetadata {
+ return DatabaseSchemaMetadata.fromPartial(base ?? {});
},
- fromPartial(object: DeepPartial<DatabaseMetadata>): DatabaseMetadata {
- const message = createBaseDatabaseMetadata();
+ fromPartial(object: DeepPartial<DatabaseSchemaMetadata>): DatabaseSchemaMetadata {
+ const message = createBaseDatabaseSchemaMetadata();
message.name = object.name ?? "";
message.schemas = object.schemas?.map((e) => SchemaMetadata.fromPartial(e)) || [];
message.characterSet = object.characterSet ?? "";
@@ -2370,6 +2524,10 @@ if (_m0.util.Long !== Long) {
_m0.configure();
}
+function isObject(value: any): boolean {
+ return typeof value === "object" && value !== null;
+}
+
function isSet(value: any): boolean {
return value !== null && value !== undefined;
}
diff --git a/proto/gen/grpc-doc/store/README.md b/proto/gen/grpc-doc/store/README.md
index 7a40f7b43e..a6830e2a0f 100644
--- a/proto/gen/grpc-doc/store/README.md
+++ b/proto/gen/grpc-doc/store/README.md
@@ -39,6 +39,8 @@
- [store/database.proto](#store_database-proto)
- [ColumnMetadata](#bytebase-store-ColumnMetadata)
- [DatabaseMetadata](#bytebase-store-DatabaseMetadata)
+ - [DatabaseMetadata.LabelsEntry](#bytebase-store-DatabaseMetadata-LabelsEntry)
+ - [DatabaseSchemaMetadata](#bytebase-store-DatabaseSchemaMetadata)
- [DependentColumn](#bytebase-store-DependentColumn)
- [ExtensionMetadata](#bytebase-store-ExtensionMetadata)
- [ForeignKeyMetadata](#bytebase-store-ForeignKeyMetadata)
@@ -626,6 +628,37 @@ ColumnMetadata is the metadata for columns.
DatabaseMetadata is the metadata for databases.
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| labels | [DatabaseMetadata.LabelsEntry](#bytebase-store-DatabaseMetadata-LabelsEntry) | repeated | |
+
+
+
+
+
+
+<a name="bytebase-store-DatabaseMetadata-LabelsEntry"></a>
+
+### DatabaseMetadata.LabelsEntry
+
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| key | [string](#string) | | |
+| value | [string](#string) | | |
+
+
+
+
+
+
+<a name="bytebase-store-DatabaseSchemaMetadata"></a>
+
+### DatabaseSchemaMetadata
+DatabaseSchemaMetadata is the schema metadata for databases.
+
+
| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| name | [string](#string) | | |
diff --git a/proto/generated-go/store/database.pb.go b/proto/generated-go/store/database.pb.go
index fe3974bdf5..ae821a901f 100644
--- a/proto/generated-go/store/database.pb.go
+++ b/proto/generated-go/store/database.pb.go
@@ -67,7 +67,7 @@ func (x TaskMetadata_State) Number() protoreflect.EnumNumber {
// Deprecated: Use TaskMetadata_State.Descriptor instead.
func (TaskMetadata_State) EnumDescriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{2, 0}
+ return file_store_database_proto_rawDescGZIP(), []int{3, 0}
}
type StreamMetadata_Type int32
@@ -113,7 +113,7 @@ func (x StreamMetadata_Type) Number() protoreflect.EnumNumber {
// Deprecated: Use StreamMetadata_Type.Descriptor instead.
func (StreamMetadata_Type) EnumDescriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{3, 0}
+ return file_store_database_proto_rawDescGZIP(), []int{4, 0}
}
type StreamMetadata_Mode int32
@@ -165,7 +165,7 @@ func (x StreamMetadata_Mode) Number() protoreflect.EnumNumber {
// Deprecated: Use StreamMetadata_Mode.Descriptor instead.
func (StreamMetadata_Mode) EnumDescriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{3, 1}
+ return file_store_database_proto_rawDescGZIP(), []int{4, 1}
}
// DatabaseMetadata is the metadata for databases.
@@ -174,6 +174,54 @@ type DatabaseMetadata struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
+ Labels map[string]string `protobuf:"bytes,1,rep,name=labels,proto3" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
+}
+
+func (x *DatabaseMetadata) Reset() {
+ *x = DatabaseMetadata{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_store_database_proto_msgTypes[0]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *DatabaseMetadata) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*DatabaseMetadata) ProtoMessage() {}
+
+func (x *DatabaseMetadata) ProtoReflect() protoreflect.Message {
+ mi := &file_store_database_proto_msgTypes[0]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use DatabaseMetadata.ProtoReflect.Descriptor instead.
+func (*DatabaseMetadata) Descriptor() ([]byte, []int) {
+ return file_store_database_proto_rawDescGZIP(), []int{0}
+}
+
+func (x *DatabaseMetadata) GetLabels() map[string]string {
+ if x != nil {
+ return x.Labels
+ }
+ return nil
+}
+
+// DatabaseSchemaMetadata is the schema metadata for databases.
+type DatabaseSchemaMetadata struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// The schemas is the list of schemas in a database.
Schemas []*SchemaMetadata `protobuf:"bytes,2,rep,name=schemas,proto3" json:"schemas,omitempty"`
@@ -189,23 +237,23 @@ type DatabaseMetadata struct {
ServiceName string `protobuf:"bytes,7,opt,name=service_name,json=serviceName,proto3" json:"service_name,omitempty"`
}
-func (x *DatabaseMetadata) Reset() {
- *x = DatabaseMetadata{}
+func (x *DatabaseSchemaMetadata) Reset() {
+ *x = DatabaseSchemaMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[0]
+ mi := &file_store_database_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
-func (x *DatabaseMetadata) String() string {
+func (x *DatabaseSchemaMetadata) String() string {
return protoimpl.X.MessageStringOf(x)
}
-func (*DatabaseMetadata) ProtoMessage() {}
+func (*DatabaseSchemaMetadata) ProtoMessage() {}
-func (x *DatabaseMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[0]
+func (x *DatabaseSchemaMetadata) ProtoReflect() protoreflect.Message {
+ mi := &file_store_database_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -216,54 +264,54 @@ func (x *DatabaseMetadata) ProtoReflect() protoreflect.Message {
return mi.MessageOf(x)
}
-// Deprecated: Use DatabaseMetadata.ProtoReflect.Descriptor instead.
-func (*DatabaseMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{0}
+// Deprecated: Use DatabaseSchemaMetadata.ProtoReflect.Descriptor instead.
+func (*DatabaseSchemaMetadata) Descriptor() ([]byte, []int) {
+ return file_store_database_proto_rawDescGZIP(), []int{1}
}
-func (x *DatabaseMetadata) GetName() string {
+func (x *DatabaseSchemaMetadata) GetName() string {
if x != nil {
return x.Name
}
return ""
}
-func (x *DatabaseMetadata) GetSchemas() []*SchemaMetadata {
+func (x *DatabaseSchemaMetadata) GetSchemas() []*SchemaMetadata {
if x != nil {
return x.Schemas
}
return nil
}
-func (x *DatabaseMetadata) GetCharacterSet() string {
+func (x *DatabaseSchemaMetadata) GetCharacterSet() string {
if x != nil {
return x.CharacterSet
}
return ""
}
-func (x *DatabaseMetadata) GetCollation() string {
+func (x *DatabaseSchemaMetadata) GetCollation() string {
if x != nil {
return x.Collation
}
return ""
}
-func (x *DatabaseMetadata) GetExtensions() []*ExtensionMetadata {
+func (x *DatabaseSchemaMetadata) GetExtensions() []*ExtensionMetadata {
if x != nil {
return x.Extensions
}
return nil
}
-func (x *DatabaseMetadata) GetDatashare() bool {
+func (x *DatabaseSchemaMetadata) GetDatashare() bool {
if x != nil {
return x.Datashare
}
return false
}
-func (x *DatabaseMetadata) GetServiceName() string {
+func (x *DatabaseSchemaMetadata) GetServiceName() string {
if x != nil {
return x.ServiceName
}
@@ -295,7 +343,7 @@ type SchemaMetadata struct {
func (x *SchemaMetadata) Reset() {
*x = SchemaMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[1]
+ mi := &file_store_database_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -308,7 +356,7 @@ func (x *SchemaMetadata) String() string {
func (*SchemaMetadata) ProtoMessage() {}
func (x *SchemaMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[1]
+ mi := &file_store_database_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -321,7 +369,7 @@ func (x *SchemaMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use SchemaMetadata.ProtoReflect.Descriptor instead.
func (*SchemaMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{1}
+ return file_store_database_proto_rawDescGZIP(), []int{2}
}
func (x *SchemaMetadata) GetName() string {
@@ -397,7 +445,7 @@ type TaskMetadata struct {
func (x *TaskMetadata) Reset() {
*x = TaskMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[2]
+ mi := &file_store_database_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -410,7 +458,7 @@ func (x *TaskMetadata) String() string {
func (*TaskMetadata) ProtoMessage() {}
func (x *TaskMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[2]
+ mi := &file_store_database_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -423,7 +471,7 @@ func (x *TaskMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use TaskMetadata.ProtoReflect.Descriptor instead.
func (*TaskMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{2}
+ return file_store_database_proto_rawDescGZIP(), []int{3}
}
func (x *TaskMetadata) GetName() string {
@@ -522,7 +570,7 @@ type StreamMetadata struct {
func (x *StreamMetadata) Reset() {
*x = StreamMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[3]
+ mi := &file_store_database_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -535,7 +583,7 @@ func (x *StreamMetadata) String() string {
func (*StreamMetadata) ProtoMessage() {}
func (x *StreamMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[3]
+ mi := &file_store_database_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -548,7 +596,7 @@ func (x *StreamMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use StreamMetadata.ProtoReflect.Descriptor instead.
func (*StreamMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{3}
+ return file_store_database_proto_rawDescGZIP(), []int{4}
}
func (x *StreamMetadata) GetName() string {
@@ -647,7 +695,7 @@ type TableMetadata struct {
func (x *TableMetadata) Reset() {
*x = TableMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[4]
+ mi := &file_store_database_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -660,7 +708,7 @@ func (x *TableMetadata) String() string {
func (*TableMetadata) ProtoMessage() {}
func (x *TableMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[4]
+ mi := &file_store_database_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -673,7 +721,7 @@ func (x *TableMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use TableMetadata.ProtoReflect.Descriptor instead.
func (*TableMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{4}
+ return file_store_database_proto_rawDescGZIP(), []int{5}
}
func (x *TableMetadata) GetName() string {
@@ -806,7 +854,7 @@ type ColumnMetadata struct {
func (x *ColumnMetadata) Reset() {
*x = ColumnMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[5]
+ mi := &file_store_database_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -819,7 +867,7 @@ func (x *ColumnMetadata) String() string {
func (*ColumnMetadata) ProtoMessage() {}
func (x *ColumnMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[5]
+ mi := &file_store_database_proto_msgTypes[6]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -832,7 +880,7 @@ func (x *ColumnMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use ColumnMetadata.ProtoReflect.Descriptor instead.
func (*ColumnMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{5}
+ return file_store_database_proto_rawDescGZIP(), []int{6}
}
func (x *ColumnMetadata) GetName() string {
@@ -924,7 +972,7 @@ type ViewMetadata struct {
func (x *ViewMetadata) Reset() {
*x = ViewMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[6]
+ mi := &file_store_database_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -937,7 +985,7 @@ func (x *ViewMetadata) String() string {
func (*ViewMetadata) ProtoMessage() {}
func (x *ViewMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[6]
+ mi := &file_store_database_proto_msgTypes[7]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -950,7 +998,7 @@ func (x *ViewMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use ViewMetadata.ProtoReflect.Descriptor instead.
func (*ViewMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{6}
+ return file_store_database_proto_rawDescGZIP(), []int{7}
}
func (x *ViewMetadata) GetName() string {
@@ -998,7 +1046,7 @@ type DependentColumn struct {
func (x *DependentColumn) Reset() {
*x = DependentColumn{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[7]
+ mi := &file_store_database_proto_msgTypes[8]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1011,7 +1059,7 @@ func (x *DependentColumn) String() string {
func (*DependentColumn) ProtoMessage() {}
func (x *DependentColumn) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[7]
+ mi := &file_store_database_proto_msgTypes[8]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1024,7 +1072,7 @@ func (x *DependentColumn) ProtoReflect() protoreflect.Message {
// Deprecated: Use DependentColumn.ProtoReflect.Descriptor instead.
func (*DependentColumn) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{7}
+ return file_store_database_proto_rawDescGZIP(), []int{8}
}
func (x *DependentColumn) GetSchema() string {
@@ -1063,7 +1111,7 @@ type FunctionMetadata struct {
func (x *FunctionMetadata) Reset() {
*x = FunctionMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[8]
+ mi := &file_store_database_proto_msgTypes[9]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1076,7 +1124,7 @@ func (x *FunctionMetadata) String() string {
func (*FunctionMetadata) ProtoMessage() {}
func (x *FunctionMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[8]
+ mi := &file_store_database_proto_msgTypes[9]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1089,7 +1137,7 @@ func (x *FunctionMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use FunctionMetadata.ProtoReflect.Descriptor instead.
func (*FunctionMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{8}
+ return file_store_database_proto_rawDescGZIP(), []int{9}
}
func (x *FunctionMetadata) GetName() string {
@@ -1132,7 +1180,7 @@ type IndexMetadata struct {
func (x *IndexMetadata) Reset() {
*x = IndexMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[9]
+ mi := &file_store_database_proto_msgTypes[10]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1145,7 +1193,7 @@ func (x *IndexMetadata) String() string {
func (*IndexMetadata) ProtoMessage() {}
func (x *IndexMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[9]
+ mi := &file_store_database_proto_msgTypes[10]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1158,7 +1206,7 @@ func (x *IndexMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use IndexMetadata.ProtoReflect.Descriptor instead.
func (*IndexMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{9}
+ return file_store_database_proto_rawDescGZIP(), []int{10}
}
func (x *IndexMetadata) GetName() string {
@@ -1229,7 +1277,7 @@ type ExtensionMetadata struct {
func (x *ExtensionMetadata) Reset() {
*x = ExtensionMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[10]
+ mi := &file_store_database_proto_msgTypes[11]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1242,7 +1290,7 @@ func (x *ExtensionMetadata) String() string {
func (*ExtensionMetadata) ProtoMessage() {}
func (x *ExtensionMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[10]
+ mi := &file_store_database_proto_msgTypes[11]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1255,7 +1303,7 @@ func (x *ExtensionMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use ExtensionMetadata.ProtoReflect.Descriptor instead.
func (*ExtensionMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{10}
+ return file_store_database_proto_rawDescGZIP(), []int{11}
}
func (x *ExtensionMetadata) GetName() string {
@@ -1316,7 +1364,7 @@ type ForeignKeyMetadata struct {
func (x *ForeignKeyMetadata) Reset() {
*x = ForeignKeyMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[11]
+ mi := &file_store_database_proto_msgTypes[12]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1329,7 +1377,7 @@ func (x *ForeignKeyMetadata) String() string {
func (*ForeignKeyMetadata) ProtoMessage() {}
func (x *ForeignKeyMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[11]
+ mi := &file_store_database_proto_msgTypes[12]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1342,7 +1390,7 @@ func (x *ForeignKeyMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use ForeignKeyMetadata.ProtoReflect.Descriptor instead.
func (*ForeignKeyMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{11}
+ return file_store_database_proto_rawDescGZIP(), []int{12}
}
func (x *ForeignKeyMetadata) GetName() string {
@@ -1416,7 +1464,7 @@ type InstanceRoleMetadata struct {
func (x *InstanceRoleMetadata) Reset() {
*x = InstanceRoleMetadata{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[12]
+ mi := &file_store_database_proto_msgTypes[13]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1429,7 +1477,7 @@ func (x *InstanceRoleMetadata) String() string {
func (*InstanceRoleMetadata) ProtoMessage() {}
func (x *InstanceRoleMetadata) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[12]
+ mi := &file_store_database_proto_msgTypes[13]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1442,7 +1490,7 @@ func (x *InstanceRoleMetadata) ProtoReflect() protoreflect.Message {
// Deprecated: Use InstanceRoleMetadata.ProtoReflect.Descriptor instead.
func (*InstanceRoleMetadata) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{12}
+ return file_store_database_proto_rawDescGZIP(), []int{13}
}
func (x *InstanceRoleMetadata) GetName() string {
@@ -1471,7 +1519,7 @@ type Secrets struct {
func (x *Secrets) Reset() {
*x = Secrets{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[13]
+ mi := &file_store_database_proto_msgTypes[14]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1484,7 +1532,7 @@ func (x *Secrets) String() string {
func (*Secrets) ProtoMessage() {}
func (x *Secrets) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[13]
+ mi := &file_store_database_proto_msgTypes[14]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1497,7 +1545,7 @@ func (x *Secrets) ProtoReflect() protoreflect.Message {
// Deprecated: Use Secrets.ProtoReflect.Descriptor instead.
func (*Secrets) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{13}
+ return file_store_database_proto_rawDescGZIP(), []int{14}
}
func (x *Secrets) GetItems() []*SecretItem {
@@ -1523,7 +1571,7 @@ type SecretItem struct {
func (x *SecretItem) Reset() {
*x = SecretItem{}
if protoimpl.UnsafeEnabled {
- mi := &file_store_database_proto_msgTypes[14]
+ mi := &file_store_database_proto_msgTypes[15]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1536,7 +1584,7 @@ func (x *SecretItem) String() string {
func (*SecretItem) ProtoMessage() {}
func (x *SecretItem) ProtoReflect() protoreflect.Message {
- mi := &file_store_database_proto_msgTypes[14]
+ mi := &file_store_database_proto_msgTypes[15]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1549,7 +1597,7 @@ func (x *SecretItem) ProtoReflect() protoreflect.Message {
// Deprecated: Use SecretItem.ProtoReflect.Descriptor instead.
func (*SecretItem) Descriptor() ([]byte, []int) {
- return file_store_database_proto_rawDescGZIP(), []int{14}
+ return file_store_database_proto_rawDescGZIP(), []int{15}
}
func (x *SecretItem) GetName() string {
@@ -1580,225 +1628,235 @@ var file_store_database_proto_rawDesc = []byte{
0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65,
0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x1a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70,
0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x73,
- 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xa7, 0x02, 0x0a, 0x10, 0x44, 0x61, 0x74, 0x61, 0x62,
- 0x61, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e,
- 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12,
- 0x38, 0x0a, 0x07, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b,
- 0x32, 0x1e, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72,
- 0x65, 0x2e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61,
- 0x52, 0x07, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x73, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x68, 0x61,
- 0x72, 0x61, 0x63, 0x74, 0x65, 0x72, 0x5f, 0x73, 0x65, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
- 0x52, 0x0c, 0x63, 0x68, 0x61, 0x72, 0x61, 0x63, 0x74, 0x65, 0x72, 0x53, 0x65, 0x74, 0x12, 0x1c,
- 0x0a, 0x09, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28,
- 0x09, 0x52, 0x09, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x41, 0x0a, 0x0a,
- 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b,
- 0x32, 0x21, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72,
- 0x65, 0x2e, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64,
- 0x61, 0x74, 0x61, 0x52, 0x0a, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x12,
- 0x1c, 0x0a, 0x09, 0x64, 0x61, 0x74, 0x61, 0x73, 0x68, 0x61, 0x72, 0x65, 0x18, 0x06, 0x20, 0x01,
- 0x28, 0x08, 0x52, 0x09, 0x64, 0x61, 0x74, 0x61, 0x73, 0x68, 0x61, 0x72, 0x65, 0x12, 0x21, 0x0a,
- 0x0c, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x07, 0x20,
- 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4e, 0x61, 0x6d, 0x65,
- 0x22, 0xbd, 0x02, 0x0a, 0x0e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x4d, 0x65, 0x74, 0x61, 0x64,
- 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
- 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x35, 0x0a, 0x06, 0x74, 0x61, 0x62, 0x6c, 0x65,
- 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61,
- 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x4d, 0x65,
- 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x06, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x73, 0x12, 0x32,
- 0x0a, 0x05, 0x76, 0x69, 0x65, 0x77, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e,
- 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x56,
- 0x69, 0x65, 0x77, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x05, 0x76, 0x69, 0x65,
- 0x77, 0x73, 0x12, 0x3e, 0x0a, 0x09, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18,
- 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65,
- 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x4d,
- 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x09, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
- 0x6e, 0x73, 0x12, 0x38, 0x0a, 0x07, 0x73, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x73, 0x18, 0x05, 0x20,
- 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73,
- 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64,
- 0x61, 0x74, 0x61, 0x52, 0x07, 0x73, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x73, 0x12, 0x32, 0x0a, 0x05,
- 0x74, 0x61, 0x73, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x62, 0x79,
- 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x54, 0x61, 0x73,
- 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x05, 0x74, 0x61, 0x73, 0x6b, 0x73,
- 0x22, 0x80, 0x03, 0x0a, 0x0c, 0x54, 0x61, 0x73, 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74,
- 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28,
- 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x18, 0x03,
+ 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x93, 0x01, 0x0a, 0x10, 0x44, 0x61, 0x74, 0x61, 0x62,
+ 0x61, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x44, 0x0a, 0x06, 0x6c,
+ 0x61, 0x62, 0x65, 0x6c, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x62, 0x79,
+ 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x44, 0x61, 0x74,
+ 0x61, 0x62, 0x61, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x4c, 0x61,
+ 0x62, 0x65, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x6c, 0x61, 0x62, 0x65, 0x6c,
+ 0x73, 0x1a, 0x39, 0x0a, 0x0b, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79,
+ 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b,
+ 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
+ 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xad, 0x02, 0x0a,
+ 0x16, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x4d,
+ 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18,
+ 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x38, 0x0a, 0x07, 0x73,
+ 0x63, 0x68, 0x65, 0x6d, 0x61, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62,
+ 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x53, 0x63,
+ 0x68, 0x65, 0x6d, 0x61, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x07, 0x73, 0x63,
+ 0x68, 0x65, 0x6d, 0x61, 0x73, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x68, 0x61, 0x72, 0x61, 0x63, 0x74,
+ 0x65, 0x72, 0x5f, 0x73, 0x65, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x68,
+ 0x61, 0x72, 0x61, 0x63, 0x74, 0x65, 0x72, 0x53, 0x65, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x6f,
+ 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63,
+ 0x6f, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x41, 0x0a, 0x0a, 0x65, 0x78, 0x74, 0x65,
+ 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62,
+ 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x45, 0x78,
+ 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52,
+ 0x0a, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x64,
+ 0x61, 0x74, 0x61, 0x73, 0x68, 0x61, 0x72, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09,
+ 0x64, 0x61, 0x74, 0x61, 0x73, 0x68, 0x61, 0x72, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x65, 0x72,
+ 0x76, 0x69, 0x63, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52,
+ 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x22, 0xbd, 0x02, 0x0a,
+ 0x0e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12,
+ 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e,
+ 0x61, 0x6d, 0x65, 0x12, 0x35, 0x0a, 0x06, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x73, 0x18, 0x02, 0x20,
+ 0x03, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73,
+ 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61,
+ 0x74, 0x61, 0x52, 0x06, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x73, 0x12, 0x32, 0x0a, 0x05, 0x76, 0x69,
+ 0x65, 0x77, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x62, 0x79, 0x74, 0x65,
+ 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x56, 0x69, 0x65, 0x77, 0x4d,
+ 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x05, 0x76, 0x69, 0x65, 0x77, 0x73, 0x12, 0x3e,
+ 0x0a, 0x09, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28,
+ 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f,
+ 0x72, 0x65, 0x2e, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64,
+ 0x61, 0x74, 0x61, 0x52, 0x09, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x38,
+ 0x0a, 0x07, 0x73, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32,
+ 0x1e, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65,
+ 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52,
+ 0x07, 0x73, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x73, 0x12, 0x32, 0x0a, 0x05, 0x74, 0x61, 0x73, 0x6b,
+ 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61,
+ 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x54, 0x61, 0x73, 0x6b, 0x4d, 0x65, 0x74,
+ 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x05, 0x74, 0x61, 0x73, 0x6b, 0x73, 0x22, 0x80, 0x03, 0x0a,
+ 0x0c, 0x54, 0x61, 0x73, 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a,
+ 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d,
+ 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69,
+ 0x64, 0x12, 0x14, 0x0a, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
+ 0x52, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65,
+ 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e,
+ 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x77, 0x61, 0x72, 0x65, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x18, 0x05,
+ 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x77, 0x61, 0x72, 0x65, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x12,
+ 0x1a, 0x0a, 0x08, 0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28,
+ 0x09, 0x52, 0x08, 0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x65, 0x12, 0x22, 0x0a, 0x0c, 0x70,
+ 0x72, 0x65, 0x64, 0x65, 0x63, 0x65, 0x73, 0x73, 0x6f, 0x72, 0x73, 0x18, 0x07, 0x20, 0x03, 0x28,
+ 0x09, 0x52, 0x0c, 0x70, 0x72, 0x65, 0x64, 0x65, 0x63, 0x65, 0x73, 0x73, 0x6f, 0x72, 0x73, 0x12,
+ 0x38, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x22,
+ 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e,
+ 0x54, 0x61, 0x73, 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x53, 0x74, 0x61,
+ 0x74, 0x65, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x6f, 0x6e,
+ 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x6f,
+ 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e,
+ 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x64, 0x65, 0x66,
+ 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x46, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65,
+ 0x12, 0x15, 0x0a, 0x11, 0x53, 0x54, 0x41, 0x54, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43,
+ 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x11, 0x0a, 0x0d, 0x53, 0x54, 0x41, 0x54, 0x45,
+ 0x5f, 0x53, 0x54, 0x41, 0x52, 0x54, 0x45, 0x44, 0x10, 0x01, 0x12, 0x13, 0x0a, 0x0f, 0x53, 0x54,
+ 0x41, 0x54, 0x45, 0x5f, 0x53, 0x55, 0x53, 0x50, 0x45, 0x4e, 0x44, 0x45, 0x44, 0x10, 0x02, 0x22,
+ 0xa5, 0x03, 0x0a, 0x0e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61,
+ 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
+ 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x5f,
+ 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x74, 0x61, 0x62, 0x6c,
+ 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x18, 0x03,
0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x63,
0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f,
- 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x77, 0x61, 0x72, 0x65, 0x68, 0x6f, 0x75,
- 0x73, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x77, 0x61, 0x72, 0x65, 0x68, 0x6f,
- 0x75, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x65, 0x18,
- 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x65, 0x12,
- 0x22, 0x0a, 0x0c, 0x70, 0x72, 0x65, 0x64, 0x65, 0x63, 0x65, 0x73, 0x73, 0x6f, 0x72, 0x73, 0x18,
- 0x07, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0c, 0x70, 0x72, 0x65, 0x64, 0x65, 0x63, 0x65, 0x73, 0x73,
- 0x6f, 0x72, 0x73, 0x12, 0x38, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x08, 0x20, 0x01,
- 0x28, 0x0e, 0x32, 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74,
- 0x6f, 0x72, 0x65, 0x2e, 0x54, 0x61, 0x73, 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61,
- 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1c, 0x0a,
- 0x09, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09,
- 0x52, 0x09, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x64,
- 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x46, 0x0a, 0x05, 0x53,
- 0x74, 0x61, 0x74, 0x65, 0x12, 0x15, 0x0a, 0x11, 0x53, 0x54, 0x41, 0x54, 0x45, 0x5f, 0x55, 0x4e,
- 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x11, 0x0a, 0x0d, 0x53,
- 0x54, 0x41, 0x54, 0x45, 0x5f, 0x53, 0x54, 0x41, 0x52, 0x54, 0x45, 0x44, 0x10, 0x01, 0x12, 0x13,
- 0x0a, 0x0f, 0x53, 0x54, 0x41, 0x54, 0x45, 0x5f, 0x53, 0x55, 0x53, 0x50, 0x45, 0x4e, 0x44, 0x45,
- 0x44, 0x10, 0x02, 0x22, 0xa5, 0x03, 0x0a, 0x0e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65,
- 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01,
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x74, 0x61,
- 0x62, 0x6c, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09,
- 0x74, 0x61, 0x62, 0x6c, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x6f, 0x77, 0x6e,
- 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x12,
- 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09,
- 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x37, 0x0a, 0x04, 0x74, 0x79, 0x70,
- 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x23, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61,
- 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d,
- 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79,
- 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x6c, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28,
- 0x08, 0x52, 0x05, 0x73, 0x74, 0x61, 0x6c, 0x65, 0x12, 0x37, 0x0a, 0x04, 0x6d, 0x6f, 0x64, 0x65,
- 0x18, 0x07, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x23, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73,
- 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65,
- 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x4d, 0x6f, 0x64, 0x65, 0x52, 0x04, 0x6d, 0x6f, 0x64,
- 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18,
- 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f,
- 0x6e, 0x22, 0x2c, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x10, 0x54, 0x59, 0x50,
- 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12,
- 0x0e, 0x0a, 0x0a, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x44, 0x45, 0x4c, 0x54, 0x41, 0x10, 0x01, 0x22,
- 0x5a, 0x0a, 0x04, 0x4d, 0x6f, 0x64, 0x65, 0x12, 0x14, 0x0a, 0x10, 0x4d, 0x4f, 0x44, 0x45, 0x5f,
- 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x10, 0x0a,
- 0x0c, 0x4d, 0x4f, 0x44, 0x45, 0x5f, 0x44, 0x45, 0x46, 0x41, 0x55, 0x4c, 0x54, 0x10, 0x01, 0x12,
- 0x14, 0x0a, 0x10, 0x4d, 0x4f, 0x44, 0x45, 0x5f, 0x41, 0x50, 0x50, 0x45, 0x4e, 0x44, 0x5f, 0x4f,
- 0x4e, 0x4c, 0x59, 0x10, 0x02, 0x12, 0x14, 0x0a, 0x10, 0x4d, 0x4f, 0x44, 0x45, 0x5f, 0x49, 0x4e,
- 0x53, 0x45, 0x52, 0x54, 0x5f, 0x4f, 0x4e, 0x4c, 0x59, 0x10, 0x03, 0x22, 0x95, 0x04, 0x0a, 0x0d,
- 0x54, 0x61, 0x62, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a,
- 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d,
- 0x65, 0x12, 0x38, 0x0a, 0x07, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03,
- 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74,
- 0x6f, 0x72, 0x65, 0x2e, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61,
- 0x74, 0x61, 0x52, 0x07, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x12, 0x37, 0x0a, 0x07, 0x69,
- 0x6e, 0x64, 0x65, 0x78, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62,
- 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x49, 0x6e,
- 0x64, 0x65, 0x78, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x07, 0x69, 0x6e, 0x64,
- 0x65, 0x78, 0x65, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x18, 0x04,
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x12, 0x1c, 0x0a, 0x09,
- 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x09, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1b, 0x0a, 0x09, 0x72, 0x6f,
- 0x77, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x72,
- 0x6f, 0x77, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x64, 0x61, 0x74, 0x61, 0x5f,
- 0x73, 0x69, 0x7a, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x64, 0x61, 0x74, 0x61,
- 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x5f, 0x73, 0x69,
- 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x53,
- 0x69, 0x7a, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x66, 0x72, 0x65, 0x65,
- 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x64, 0x61, 0x74, 0x61, 0x46, 0x72, 0x65, 0x65,
- 0x12, 0x25, 0x0a, 0x0e, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f,
- 0x6e, 0x73, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65,
- 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65,
- 0x6e, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e,
- 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74,
- 0x69, 0x6f, 0x6e, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x63, 0x6c, 0x61, 0x73, 0x73,
- 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x21, 0x0a, 0x0c, 0x75, 0x73, 0x65,
- 0x72, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x0b, 0x75, 0x73, 0x65, 0x72, 0x43, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x45, 0x0a, 0x0c,
- 0x66, 0x6f, 0x72, 0x65, 0x69, 0x67, 0x6e, 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x0c, 0x20, 0x03,
- 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74,
- 0x6f, 0x72, 0x65, 0x2e, 0x46, 0x6f, 0x72, 0x65, 0x69, 0x67, 0x6e, 0x4b, 0x65, 0x79, 0x4d, 0x65,
- 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x66, 0x6f, 0x72, 0x65, 0x69, 0x67, 0x6e, 0x4b,
- 0x65, 0x79, 0x73, 0x22, 0xd0, 0x02, 0x0a, 0x0e, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x4d, 0x65,
- 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01,
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x6f,
- 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x6f,
- 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x36, 0x0a, 0x07, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c,
- 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67,
- 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x07, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x1a,
- 0x0a, 0x08, 0x6e, 0x75, 0x6c, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08,
- 0x52, 0x08, 0x6e, 0x75, 0x6c, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79,
- 0x70, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x23,
- 0x0a, 0x0d, 0x63, 0x68, 0x61, 0x72, 0x61, 0x63, 0x74, 0x65, 0x72, 0x5f, 0x73, 0x65, 0x74, 0x18,
- 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x68, 0x61, 0x72, 0x61, 0x63, 0x74, 0x65, 0x72,
- 0x53, 0x65, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e,
- 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f,
- 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x08, 0x20, 0x01,
- 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x63,
- 0x6c, 0x61, 0x73, 0x73, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x09, 0x20,
- 0x01, 0x28, 0x09, 0x52, 0x0e, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74,
- 0x69, 0x6f, 0x6e, 0x12, 0x21, 0x0a, 0x0c, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x63, 0x6f, 0x6d, 0x6d,
- 0x65, 0x6e, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x75, 0x73, 0x65, 0x72, 0x43,
- 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0xaa, 0x01, 0x0a, 0x0c, 0x56, 0x69, 0x65, 0x77, 0x4d,
+ 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x37, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x05, 0x20,
+ 0x01, 0x28, 0x0e, 0x32, 0x23, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73,
+ 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64,
+ 0x61, 0x74, 0x61, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x14,
+ 0x0a, 0x05, 0x73, 0x74, 0x61, 0x6c, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x73,
+ 0x74, 0x61, 0x6c, 0x65, 0x12, 0x37, 0x0a, 0x04, 0x6d, 0x6f, 0x64, 0x65, 0x18, 0x07, 0x20, 0x01,
+ 0x28, 0x0e, 0x32, 0x23, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74,
+ 0x6f, 0x72, 0x65, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61,
+ 0x74, 0x61, 0x2e, 0x4d, 0x6f, 0x64, 0x65, 0x52, 0x04, 0x6d, 0x6f, 0x64, 0x65, 0x12, 0x1e, 0x0a,
+ 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28,
+ 0x09, 0x52, 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x2c, 0x0a,
+ 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x10, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e,
+ 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x0e, 0x0a, 0x0a, 0x54,
+ 0x59, 0x50, 0x45, 0x5f, 0x44, 0x45, 0x4c, 0x54, 0x41, 0x10, 0x01, 0x22, 0x5a, 0x0a, 0x04, 0x4d,
+ 0x6f, 0x64, 0x65, 0x12, 0x14, 0x0a, 0x10, 0x4d, 0x4f, 0x44, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50,
+ 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x10, 0x0a, 0x0c, 0x4d, 0x4f, 0x44,
+ 0x45, 0x5f, 0x44, 0x45, 0x46, 0x41, 0x55, 0x4c, 0x54, 0x10, 0x01, 0x12, 0x14, 0x0a, 0x10, 0x4d,
+ 0x4f, 0x44, 0x45, 0x5f, 0x41, 0x50, 0x50, 0x45, 0x4e, 0x44, 0x5f, 0x4f, 0x4e, 0x4c, 0x59, 0x10,
+ 0x02, 0x12, 0x14, 0x0a, 0x10, 0x4d, 0x4f, 0x44, 0x45, 0x5f, 0x49, 0x4e, 0x53, 0x45, 0x52, 0x54,
+ 0x5f, 0x4f, 0x4e, 0x4c, 0x59, 0x10, 0x03, 0x22, 0x95, 0x04, 0x0a, 0x0d, 0x54, 0x61, 0x62, 0x6c,
+ 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d,
+ 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x38, 0x0a,
+ 0x07, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e,
+ 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e,
+ 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x07,
+ 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x12, 0x37, 0x0a, 0x07, 0x69, 0x6e, 0x64, 0x65, 0x78,
+ 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62,
+ 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x4d,
+ 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x07, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x65, 0x73,
+ 0x12, 0x16, 0x0a, 0x06, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09,
+ 0x52, 0x06, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x6f, 0x6c, 0x6c,
+ 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x6f, 0x6c,
+ 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1b, 0x0a, 0x09, 0x72, 0x6f, 0x77, 0x5f, 0x63, 0x6f,
+ 0x75, 0x6e, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x72, 0x6f, 0x77, 0x43, 0x6f,
+ 0x75, 0x6e, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x73, 0x69, 0x7a, 0x65,
+ 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x64, 0x61, 0x74, 0x61, 0x53, 0x69, 0x7a, 0x65,
+ 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x08,
+ 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x53, 0x69, 0x7a, 0x65, 0x12,
+ 0x1b, 0x0a, 0x09, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x66, 0x72, 0x65, 0x65, 0x18, 0x09, 0x20, 0x01,
+ 0x28, 0x03, 0x52, 0x08, 0x64, 0x61, 0x74, 0x61, 0x46, 0x72, 0x65, 0x65, 0x12, 0x25, 0x0a, 0x0e,
+ 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x0a,
+ 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69,
+ 0x6f, 0x6e, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x0b,
+ 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x26, 0x0a,
+ 0x0e, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18,
+ 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x69, 0x66, 0x69, 0x63,
+ 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x21, 0x0a, 0x0c, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x63, 0x6f,
+ 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x75, 0x73, 0x65,
+ 0x72, 0x43, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x45, 0x0a, 0x0c, 0x66, 0x6f, 0x72, 0x65,
+ 0x69, 0x67, 0x6e, 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x0c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22,
+ 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e,
+ 0x46, 0x6f, 0x72, 0x65, 0x69, 0x67, 0x6e, 0x4b, 0x65, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61,
+ 0x74, 0x61, 0x52, 0x0b, 0x66, 0x6f, 0x72, 0x65, 0x69, 0x67, 0x6e, 0x4b, 0x65, 0x79, 0x73, 0x22,
+ 0xd0, 0x02, 0x0a, 0x0e, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61,
+ 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
+ 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69,
+ 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69,
+ 0x6f, 0x6e, 0x12, 0x36, 0x0a, 0x07, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x18, 0x03, 0x20,
+ 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f,
+ 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x56, 0x61, 0x6c, 0x75,
+ 0x65, 0x52, 0x07, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x75,
+ 0x6c, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x6e, 0x75,
+ 0x6c, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x05,
+ 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x68,
+ 0x61, 0x72, 0x61, 0x63, 0x74, 0x65, 0x72, 0x5f, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28,
+ 0x09, 0x52, 0x0c, 0x63, 0x68, 0x61, 0x72, 0x61, 0x63, 0x74, 0x65, 0x72, 0x53, 0x65, 0x74, 0x12,
+ 0x1c, 0x0a, 0x09, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01,
+ 0x28, 0x09, 0x52, 0x09, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x18, 0x0a,
+ 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07,
+ 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x63, 0x6c, 0x61, 0x73, 0x73,
+ 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52,
+ 0x0e, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12,
+ 0x21, 0x0a, 0x0c, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18,
+ 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x75, 0x73, 0x65, 0x72, 0x43, 0x6f, 0x6d, 0x6d, 0x65,
+ 0x6e, 0x74, 0x22, 0xaa, 0x01, 0x0a, 0x0c, 0x56, 0x69, 0x65, 0x77, 0x4d, 0x65, 0x74, 0x61, 0x64,
+ 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
+ 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e,
+ 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x64, 0x65, 0x66,
+ 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65,
+ 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e,
+ 0x74, 0x12, 0x4c, 0x0a, 0x11, 0x64, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x74, 0x5f, 0x63,
+ 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62,
+ 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x44, 0x65,
+ 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x52, 0x10, 0x64,
+ 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x22,
+ 0x57, 0x0a, 0x0f, 0x44, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x6c, 0x75,
+ 0x6d, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x01, 0x20, 0x01,
+ 0x28, 0x09, 0x52, 0x06, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x61,
+ 0x62, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x61, 0x62, 0x6c, 0x65,
+ 0x12, 0x16, 0x0a, 0x06, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
+ 0x52, 0x06, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x22, 0x46, 0x0a, 0x10, 0x46, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04,
+ 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65,
+ 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02,
+ 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e,
+ 0x22, 0xbf, 0x01, 0x0a, 0x0d, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61,
+ 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
+ 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73,
+ 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0b, 0x65, 0x78, 0x70,
+ 0x72, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65,
+ 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06,
+ 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x75, 0x6e,
+ 0x69, 0x71, 0x75, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x72, 0x69, 0x6d, 0x61, 0x72, 0x79, 0x18,
+ 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x70, 0x72, 0x69, 0x6d, 0x61, 0x72, 0x79, 0x12, 0x18,
+ 0x0a, 0x07, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52,
+ 0x07, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d,
+ 0x65, 0x6e, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x65,
+ 0x6e, 0x74, 0x22, 0x7b, 0x0a, 0x11, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x4d,
0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18,
- 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x64,
- 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63,
- 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f,
- 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x4c, 0x0a, 0x11, 0x64, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65,
- 0x6e, 0x74, 0x5f, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b,
- 0x32, 0x1f, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72,
- 0x65, 0x2e, 0x44, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x6c, 0x75, 0x6d,
- 0x6e, 0x52, 0x10, 0x64, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x6c, 0x75,
- 0x6d, 0x6e, 0x73, 0x22, 0x57, 0x0a, 0x0f, 0x44, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x74,
- 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61,
- 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x14,
- 0x0a, 0x05, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74,
- 0x61, 0x62, 0x6c, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x18, 0x03,
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x22, 0x46, 0x0a, 0x10,
- 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61,
- 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
- 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x69,
- 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x69,
- 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xbf, 0x01, 0x0a, 0x0d, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x4d, 0x65,
+ 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x73,
+ 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x63, 0x68,
+ 0x65, 0x6d, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03,
+ 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x20, 0x0a,
+ 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01,
+ 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x22,
+ 0xa2, 0x02, 0x0a, 0x12, 0x46, 0x6f, 0x72, 0x65, 0x69, 0x67, 0x6e, 0x4b, 0x65, 0x79, 0x4d, 0x65,
0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01,
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x65, 0x78,
- 0x70, 0x72, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52,
- 0x0b, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x12, 0x0a, 0x04,
- 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65,
- 0x12, 0x16, 0x0a, 0x06, 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08,
- 0x52, 0x06, 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x72, 0x69, 0x6d,
- 0x61, 0x72, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x70, 0x72, 0x69, 0x6d, 0x61,
- 0x72, 0x79, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x18, 0x06, 0x20,
- 0x01, 0x28, 0x08, 0x52, 0x07, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07,
- 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63,
- 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x7b, 0x0a, 0x11, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73,
- 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e,
- 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12,
- 0x16, 0x0a, 0x06, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x06, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69,
- 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f,
- 0x6e, 0x12, 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e,
- 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74,
- 0x69, 0x6f, 0x6e, 0x22, 0xa2, 0x02, 0x0a, 0x12, 0x46, 0x6f, 0x72, 0x65, 0x69, 0x67, 0x6e, 0x4b,
- 0x65, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61,
- 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x18,
- 0x0a, 0x07, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52,
- 0x07, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x12, 0x2b, 0x0a, 0x11, 0x72, 0x65, 0x66, 0x65,
- 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x5f, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x03, 0x20,
- 0x01, 0x28, 0x09, 0x52, 0x10, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x53,
- 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x29, 0x0a, 0x10, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e,
- 0x63, 0x65, 0x64, 0x5f, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x0f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x54, 0x61, 0x62, 0x6c, 0x65,
- 0x12, 0x2d, 0x0a, 0x12, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x5f, 0x63,
- 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x52, 0x11, 0x72, 0x65,
- 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x12,
- 0x1b, 0x0a, 0x09, 0x6f, 0x6e, 0x5f, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x18, 0x06, 0x20, 0x01,
- 0x28, 0x09, 0x52, 0x08, 0x6f, 0x6e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x1b, 0x0a, 0x09,
- 0x6f, 0x6e, 0x5f, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x08, 0x6f, 0x6e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x6d, 0x61, 0x74,
- 0x63, 0x68, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6d,
- 0x61, 0x74, 0x63, 0x68, 0x54, 0x79, 0x70, 0x65, 0x22, 0x40, 0x0a, 0x14, 0x49, 0x6e, 0x73, 0x74,
- 0x61, 0x6e, 0x63, 0x65, 0x52, 0x6f, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61,
- 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
- 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x67, 0x72, 0x61, 0x6e, 0x74, 0x18, 0x07, 0x20,
- 0x01, 0x28, 0x09, 0x52, 0x05, 0x67, 0x72, 0x61, 0x6e, 0x74, 0x22, 0x3b, 0x0a, 0x07, 0x53, 0x65,
- 0x63, 0x72, 0x65, 0x74, 0x73, 0x12, 0x30, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x01,
- 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e,
- 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2e, 0x53, 0x65, 0x63, 0x72, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d,
- 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x22, 0x58, 0x0a, 0x0a, 0x53, 0x65, 0x63, 0x72, 0x65,
- 0x74, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20,
- 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c,
- 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12,
- 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03,
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f,
- 0x6e, 0x42, 0x14, 0x5a, 0x12, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x64, 0x2d, 0x67,
- 0x6f, 0x2f, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
+ 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f,
+ 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6c,
+ 0x75, 0x6d, 0x6e, 0x73, 0x12, 0x2b, 0x0a, 0x11, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63,
+ 0x65, 0x64, 0x5f, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52,
+ 0x10, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x53, 0x63, 0x68, 0x65, 0x6d,
+ 0x61, 0x12, 0x29, 0x0a, 0x10, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x5f,
+ 0x74, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x72, 0x65, 0x66,
+ 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x2d, 0x0a, 0x12,
+ 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x64, 0x5f, 0x63, 0x6f, 0x6c, 0x75, 0x6d,
+ 0x6e, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x52, 0x11, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65,
+ 0x6e, 0x63, 0x65, 0x64, 0x43, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x6f,
+ 0x6e, 0x5f, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08,
+ 0x6f, 0x6e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x6f, 0x6e, 0x5f, 0x75,
+ 0x70, 0x64, 0x61, 0x74, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6f, 0x6e, 0x55,
+ 0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x74,
+ 0x79, 0x70, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6d, 0x61, 0x74, 0x63, 0x68,
+ 0x54, 0x79, 0x70, 0x65, 0x22, 0x40, 0x0a, 0x14, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65,
+ 0x52, 0x6f, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04,
+ 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65,
+ 0x12, 0x14, 0x0a, 0x05, 0x67, 0x72, 0x61, 0x6e, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52,
+ 0x05, 0x67, 0x72, 0x61, 0x6e, 0x74, 0x22, 0x3b, 0x0a, 0x07, 0x53, 0x65, 0x63, 0x72, 0x65, 0x74,
+ 0x73, 0x12, 0x30, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b,
+ 0x32, 0x1a, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72,
+ 0x65, 0x2e, 0x53, 0x65, 0x63, 0x72, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x05, 0x69, 0x74,
+ 0x65, 0x6d, 0x73, 0x22, 0x58, 0x0a, 0x0a, 0x53, 0x65, 0x63, 0x72, 0x65, 0x74, 0x49, 0x74, 0x65,
+ 0x6d, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
+ 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02,
+ 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x64,
+ 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
+ 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x14, 0x5a,
+ 0x12, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x64, 0x2d, 0x67, 0x6f, 0x2f, 0x73, 0x74,
+ 0x6f, 0x72, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
@@ -1814,50 +1872,53 @@ func file_store_database_proto_rawDescGZIP() []byte {
}
var file_store_database_proto_enumTypes = make([]protoimpl.EnumInfo, 3)
-var file_store_database_proto_msgTypes = make([]protoimpl.MessageInfo, 15)
+var file_store_database_proto_msgTypes = make([]protoimpl.MessageInfo, 17)
var file_store_database_proto_goTypes = []interface{}{
(TaskMetadata_State)(0), // 0: bytebase.store.TaskMetadata.State
(StreamMetadata_Type)(0), // 1: bytebase.store.StreamMetadata.Type
(StreamMetadata_Mode)(0), // 2: bytebase.store.StreamMetadata.Mode
(*DatabaseMetadata)(nil), // 3: bytebase.store.DatabaseMetadata
- (*SchemaMetadata)(nil), // 4: bytebase.store.SchemaMetadata
- (*TaskMetadata)(nil), // 5: bytebase.store.TaskMetadata
- (*StreamMetadata)(nil), // 6: bytebase.store.StreamMetadata
- (*TableMetadata)(nil), // 7: bytebase.store.TableMetadata
- (*ColumnMetadata)(nil), // 8: bytebase.store.ColumnMetadata
- (*ViewMetadata)(nil), // 9: bytebase.store.ViewMetadata
- (*DependentColumn)(nil), // 10: bytebase.store.DependentColumn
- (*FunctionMetadata)(nil), // 11: bytebase.store.FunctionMetadata
- (*IndexMetadata)(nil), // 12: bytebase.store.IndexMetadata
- (*ExtensionMetadata)(nil), // 13: bytebase.store.ExtensionMetadata
- (*ForeignKeyMetadata)(nil), // 14: bytebase.store.ForeignKeyMetadata
- (*InstanceRoleMetadata)(nil), // 15: bytebase.store.InstanceRoleMetadata
- (*Secrets)(nil), // 16: bytebase.store.Secrets
- (*SecretItem)(nil), // 17: bytebase.store.SecretItem
- (*wrapperspb.StringValue)(nil), // 18: google.protobuf.StringValue
+ (*DatabaseSchemaMetadata)(nil), // 4: bytebase.store.DatabaseSchemaMetadata
+ (*SchemaMetadata)(nil), // 5: bytebase.store.SchemaMetadata
+ (*TaskMetadata)(nil), // 6: bytebase.store.TaskMetadata
+ (*StreamMetadata)(nil), // 7: bytebase.store.StreamMetadata
+ (*TableMetadata)(nil), // 8: bytebase.store.TableMetadata
+ (*ColumnMetadata)(nil), // 9: bytebase.store.ColumnMetadata
+ (*ViewMetadata)(nil), // 10: bytebase.store.ViewMetadata
+ (*DependentColumn)(nil), // 11: bytebase.store.DependentColumn
+ (*FunctionMetadata)(nil), // 12: bytebase.store.FunctionMetadata
+ (*IndexMetadata)(nil), // 13: bytebase.store.IndexMetadata
+ (*ExtensionMetadata)(nil), // 14: bytebase.store.ExtensionMetadata
+ (*ForeignKeyMetadata)(nil), // 15: bytebase.store.ForeignKeyMetadata
+ (*InstanceRoleMetadata)(nil), // 16: bytebase.store.InstanceRoleMetadata
+ (*Secrets)(nil), // 17: bytebase.store.Secrets
+ (*SecretItem)(nil), // 18: bytebase.store.SecretItem
+ nil, // 19: bytebase.store.DatabaseMetadata.LabelsEntry
+ (*wrapperspb.StringValue)(nil), // 20: google.protobuf.StringValue
}
var file_store_database_proto_depIdxs = []int32{
- 4, // 0: bytebase.store.DatabaseMetadata.schemas:type_name -> bytebase.store.SchemaMetadata
- 13, // 1: bytebase.store.DatabaseMetadata.extensions:type_name -> bytebase.store.ExtensionMetadata
- 7, // 2: bytebase.store.SchemaMetadata.tables:type_name -> bytebase.store.TableMetadata
- 9, // 3: bytebase.store.SchemaMetadata.views:type_name -> bytebase.store.ViewMetadata
- 11, // 4: bytebase.store.SchemaMetadata.functions:type_name -> bytebase.store.FunctionMetadata
- 6, // 5: bytebase.store.SchemaMetadata.streams:type_name -> bytebase.store.StreamMetadata
- 5, // 6: bytebase.store.SchemaMetadata.tasks:type_name -> bytebase.store.TaskMetadata
- 0, // 7: bytebase.store.TaskMetadata.state:type_name -> bytebase.store.TaskMetadata.State
- 1, // 8: bytebase.store.StreamMetadata.type:type_name -> bytebase.store.StreamMetadata.Type
- 2, // 9: bytebase.store.StreamMetadata.mode:type_name -> bytebase.store.StreamMetadata.Mode
- 8, // 10: bytebase.store.TableMetadata.columns:type_name -> bytebase.store.ColumnMetadata
- 12, // 11: bytebase.store.TableMetadata.indexes:type_name -> bytebase.store.IndexMetadata
- 14, // 12: bytebase.store.TableMetadata.foreign_keys:type_name -> bytebase.store.ForeignKeyMetadata
- 18, // 13: bytebase.store.ColumnMetadata.default:type_name -> google.protobuf.StringValue
- 10, // 14: bytebase.store.ViewMetadata.dependent_columns:type_name -> bytebase.store.DependentColumn
- 17, // 15: bytebase.store.Secrets.items:type_name -> bytebase.store.SecretItem
- 16, // [16:16] is the sub-list for method output_type
- 16, // [16:16] is the sub-list for method input_type
- 16, // [16:16] is the sub-list for extension type_name
- 16, // [16:16] is the sub-list for extension extendee
- 0, // [0:16] is the sub-list for field type_name
+ 19, // 0: bytebase.store.DatabaseMetadata.labels:type_name -> bytebase.store.DatabaseMetadata.LabelsEntry
+ 5, // 1: bytebase.store.DatabaseSchemaMetadata.schemas:type_name -> bytebase.store.SchemaMetadata
+ 14, // 2: bytebase.store.DatabaseSchemaMetadata.extensions:type_name -> bytebase.store.ExtensionMetadata
+ 8, // 3: bytebase.store.SchemaMetadata.tables:type_name -> bytebase.store.TableMetadata
+ 10, // 4: bytebase.store.SchemaMetadata.views:type_name -> bytebase.store.ViewMetadata
+ 12, // 5: bytebase.store.SchemaMetadata.functions:type_name -> bytebase.store.FunctionMetadata
+ 7, // 6: bytebase.store.SchemaMetadata.streams:type_name -> bytebase.store.StreamMetadata
+ 6, // 7: bytebase.store.SchemaMetadata.tasks:type_name -> bytebase.store.TaskMetadata
+ 0, // 8: bytebase.store.TaskMetadata.state:type_name -> bytebase.store.TaskMetadata.State
+ 1, // 9: bytebase.store.StreamMetadata.type:type_name -> bytebase.store.StreamMetadata.Type
+ 2, // 10: bytebase.store.StreamMetadata.mode:type_name -> bytebase.store.StreamMetadata.Mode
+ 9, // 11: bytebase.store.TableMetadata.columns:type_name -> bytebase.store.ColumnMetadata
+ 13, // 12: bytebase.store.TableMetadata.indexes:type_name -> bytebase.store.IndexMetadata
+ 15, // 13: bytebase.store.TableMetadata.foreign_keys:type_name -> bytebase.store.ForeignKeyMetadata
+ 20, // 14: bytebase.store.ColumnMetadata.default:type_name -> google.protobuf.StringValue
+ 11, // 15: bytebase.store.ViewMetadata.dependent_columns:type_name -> bytebase.store.DependentColumn
+ 18, // 16: bytebase.store.Secrets.items:type_name -> bytebase.store.SecretItem
+ 17, // [17:17] is the sub-list for method output_type
+ 17, // [17:17] is the sub-list for method input_type
+ 17, // [17:17] is the sub-list for extension type_name
+ 17, // [17:17] is the sub-list for extension extendee
+ 0, // [0:17] is the sub-list for field type_name
}
func init() { file_store_database_proto_init() }
@@ -1879,7 +1940,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*SchemaMetadata); i {
+ switch v := v.(*DatabaseSchemaMetadata); i {
case 0:
return &v.state
case 1:
@@ -1891,7 +1952,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*TaskMetadata); i {
+ switch v := v.(*SchemaMetadata); i {
case 0:
return &v.state
case 1:
@@ -1903,7 +1964,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*StreamMetadata); i {
+ switch v := v.(*TaskMetadata); i {
case 0:
return &v.state
case 1:
@@ -1915,7 +1976,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*TableMetadata); i {
+ switch v := v.(*StreamMetadata); i {
case 0:
return &v.state
case 1:
@@ -1927,7 +1988,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*ColumnMetadata); i {
+ switch v := v.(*TableMetadata); i {
case 0:
return &v.state
case 1:
@@ -1939,7 +2000,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*ViewMetadata); i {
+ switch v := v.(*ColumnMetadata); i {
case 0:
return &v.state
case 1:
@@ -1951,7 +2012,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*DependentColumn); i {
+ switch v := v.(*ViewMetadata); i {
case 0:
return &v.state
case 1:
@@ -1963,7 +2024,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*FunctionMetadata); i {
+ switch v := v.(*DependentColumn); i {
case 0:
return &v.state
case 1:
@@ -1975,7 +2036,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*IndexMetadata); i {
+ switch v := v.(*FunctionMetadata); i {
case 0:
return &v.state
case 1:
@@ -1987,7 +2048,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*ExtensionMetadata); i {
+ switch v := v.(*IndexMetadata); i {
case 0:
return &v.state
case 1:
@@ -1999,7 +2060,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*ForeignKeyMetadata); i {
+ switch v := v.(*ExtensionMetadata); i {
case 0:
return &v.state
case 1:
@@ -2011,7 +2072,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*InstanceRoleMetadata); i {
+ switch v := v.(*ForeignKeyMetadata); i {
case 0:
return &v.state
case 1:
@@ -2023,7 +2084,7 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {
- switch v := v.(*Secrets); i {
+ switch v := v.(*InstanceRoleMetadata); i {
case 0:
return &v.state
case 1:
@@ -2035,6 +2096,18 @@ func file_store_database_proto_init() {
}
}
file_store_database_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Secrets); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_store_database_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*SecretItem); i {
case 0:
return &v.state
@@ -2053,7 +2126,7 @@ func file_store_database_proto_init() {
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_store_database_proto_rawDesc,
NumEnums: 3,
- NumMessages: 15,
+ NumMessages: 17,
NumExtensions: 0,
NumServices: 0,
},
diff --git a/proto/store/database.proto b/proto/store/database.proto
index 955f8f1f6c..4e4be32979 100644
--- a/proto/store/database.proto
+++ b/proto/store/database.proto
@@ -8,6 +8,11 @@ option go_package = "generated-go/store";
// DatabaseMetadata is the metadata for databases.
message DatabaseMetadata {
+ map<string, string> labels = 1;
+}
+
+// DatabaseSchemaMetadata is the schema metadata for databases.
+message DatabaseSchemaMetadata {
string name = 1;
// The schemas is the list of schemas in a database.